@modern-js/repo-generator 0.0.0-next-20230203070739 → 0.0.0-next-20230206051444

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.
Files changed (2) hide show
  1. package/dist/index.js +188 -153
  2. package/package.json +11 -11
package/dist/index.js CHANGED
@@ -35757,7 +35757,7 @@ var require_nodeEnv = __commonJS({
35757
35757
  });
35758
35758
  }
35759
35759
  exports.canUseNpm = canUseNpm3;
35760
- function canUseYarn3() {
35760
+ function canUseYarn2() {
35761
35761
  return __async(this, null, function* () {
35762
35762
  try {
35763
35763
  yield (0, compiled_1.execa)("yarn", ["--version"], { env: process.env });
@@ -35767,7 +35767,7 @@ var require_nodeEnv = __commonJS({
35767
35767
  }
35768
35768
  });
35769
35769
  }
35770
- exports.canUseYarn = canUseYarn3;
35770
+ exports.canUseYarn = canUseYarn2;
35771
35771
  function canUsePnpm3() {
35772
35772
  return __async(this, null, function* () {
35773
35773
  try {
@@ -44405,7 +44405,7 @@ var require_env = __commonJS({
44405
44405
  exports.canUseNpm = canUseNpm3;
44406
44406
  exports.canUseNvm = canUseNvm;
44407
44407
  exports.canUsePnpm = canUsePnpm3;
44408
- exports.canUseYarn = canUseYarn3;
44408
+ exports.canUseYarn = canUseYarn2;
44409
44409
  var _utils = require_dist();
44410
44410
  function canUseNvm() {
44411
44411
  return __async(this, null, function* () {
@@ -44432,7 +44432,7 @@ var require_env = __commonJS({
44432
44432
  }
44433
44433
  });
44434
44434
  }
44435
- function canUseYarn3() {
44435
+ function canUseYarn2() {
44436
44436
  return __async(this, null, function* () {
44437
44437
  try {
44438
44438
  yield (0, _utils.execa)("yarn", ["--version"], {
@@ -45468,14 +45468,14 @@ var require_packageManager = __commonJS({
45468
45468
  value: true
45469
45469
  });
45470
45470
  exports.canUsePnpm = canUsePnpm3;
45471
- exports.canUseYarn = canUseYarn3;
45471
+ exports.canUseYarn = canUseYarn2;
45472
45472
  exports.runInstall = runInstall;
45473
45473
  var _path = _interopRequireDefault(require("path"));
45474
45474
  var _utils = require_dist();
45475
45475
  function _interopRequireDefault(obj) {
45476
45476
  return obj && obj.__esModule ? obj : { default: obj };
45477
45477
  }
45478
- function canUseYarn3() {
45478
+ function canUseYarn2() {
45479
45479
  return __async(this, null, function* () {
45480
45480
  try {
45481
45481
  yield (0, _utils.execa)("yarn", ["--version"], {
@@ -45522,7 +45522,7 @@ var require_packageManager = __commonJS({
45522
45522
  params.push(`--registry=${registryUrl}`);
45523
45523
  }
45524
45524
  yield (0, _utils.execa)("pnpm", params, options);
45525
- } else if (yield canUseYarn3()) {
45525
+ } else if (yield canUseYarn2()) {
45526
45526
  const params = ["install", "--production", "--silent", "--ignore-scripts"];
45527
45527
  if (registryUrl) {
45528
45528
  params.push(`--registry=${registryUrl}`);
@@ -48075,9 +48075,9 @@ var require_high_level_opt = __commonJS({
48075
48075
  }
48076
48076
  });
48077
48077
 
48078
- // ../../../../node_modules/.pnpm/minipass@4.0.1/node_modules/minipass/index.js
48078
+ // ../../../../node_modules/.pnpm/minipass@4.0.2/node_modules/minipass/index.js
48079
48079
  var require_minipass = __commonJS({
48080
- "../../../../node_modules/.pnpm/minipass@4.0.1/node_modules/minipass/index.js"(exports, module2) {
48080
+ "../../../../node_modules/.pnpm/minipass@4.0.2/node_modules/minipass/index.js"(exports, module2) {
48081
48081
  "use strict";
48082
48082
  var proc = typeof process === "object" && process ? process : {
48083
48083
  stdout: null,
@@ -48107,6 +48107,7 @@ var require_minipass = __commonJS({
48107
48107
  var BUFFERSHIFT = Symbol("bufferShift");
48108
48108
  var OBJECTMODE = Symbol("objectMode");
48109
48109
  var DESTROYED = Symbol("destroyed");
48110
+ var ERROR = Symbol("error");
48110
48111
  var EMITDATA = Symbol("emitData");
48111
48112
  var EMITEND = Symbol("emitEnd");
48112
48113
  var EMITEND2 = Symbol("emitEnd2");
@@ -48217,10 +48218,13 @@ var require_minipass = __commonJS({
48217
48218
  if (this[EOF])
48218
48219
  throw new Error("write after end");
48219
48220
  if (this[DESTROYED]) {
48220
- this.emit("error", Object.assign(
48221
- new Error("Cannot call write after a stream was destroyed"),
48222
- { code: "ERR_STREAM_DESTROYED" }
48223
- ));
48221
+ this.emit(
48222
+ "error",
48223
+ Object.assign(
48224
+ new Error("Cannot call write after a stream was destroyed"),
48225
+ { code: "ERR_STREAM_DESTROYED" }
48226
+ )
48227
+ );
48224
48228
  return true;
48225
48229
  }
48226
48230
  if (typeof encoding === "function")
@@ -48388,7 +48392,9 @@ var require_minipass = __commonJS({
48388
48392
  if (opts.end)
48389
48393
  dest.end();
48390
48394
  } else {
48391
- this[PIPES].push(!opts.proxyErrors ? new Pipe(this, dest, opts) : new PipeProxyErrors(this, dest, opts));
48395
+ this[PIPES].push(
48396
+ !opts.proxyErrors ? new Pipe(this, dest, opts) : new PipeProxyErrors(this, dest, opts)
48397
+ );
48392
48398
  if (this[ASYNC])
48393
48399
  defer(() => this[RESUME]());
48394
48400
  else
@@ -48453,6 +48459,7 @@ var require_minipass = __commonJS({
48453
48459
  return ret2;
48454
48460
  } else if (ev === "error") {
48455
48461
  this[EMITTED_ERROR] = data;
48462
+ super.emit(ERROR, data);
48456
48463
  const ret2 = super.emit("error", data);
48457
48464
  this[MAYBE_EMIT_END]();
48458
48465
  return ret2;
@@ -48518,7 +48525,9 @@ var require_minipass = __commonJS({
48518
48525
  return p.then(() => buf);
48519
48526
  }
48520
48527
  concat() {
48521
- return this[OBJECTMODE] ? Promise.reject(new Error("cannot concat in objectMode")) : this.collect().then((buf) => this[OBJECTMODE] ? Promise.reject(new Error("cannot concat in objectMode")) : this[ENCODING] ? buf.join("") : Buffer.concat(buf, buf.dataLength));
48528
+ return this[OBJECTMODE] ? Promise.reject(new Error("cannot concat in objectMode")) : this.collect().then(
48529
+ (buf) => this[OBJECTMODE] ? Promise.reject(new Error("cannot concat in objectMode")) : this[ENCODING] ? buf.join("") : Buffer.concat(buf, buf.dataLength)
48530
+ );
48522
48531
  }
48523
48532
  promise() {
48524
48533
  return new Promise((resolve, reject) => {
@@ -48528,17 +48537,26 @@ var require_minipass = __commonJS({
48528
48537
  });
48529
48538
  }
48530
48539
  [ASYNCITERATOR]() {
48540
+ let stopped = false;
48541
+ const stop = () => {
48542
+ this.pause();
48543
+ stopped = true;
48544
+ return Promise.resolve({ done: true });
48545
+ };
48531
48546
  const next = () => {
48547
+ if (stopped)
48548
+ return stop();
48532
48549
  const res = this.read();
48533
48550
  if (res !== null)
48534
48551
  return Promise.resolve({ done: false, value: res });
48535
48552
  if (this[EOF])
48536
- return Promise.resolve({ done: true });
48553
+ return stop();
48537
48554
  let resolve = null;
48538
48555
  let reject = null;
48539
48556
  const onerr = (er) => {
48540
48557
  this.removeListener("data", ondata);
48541
48558
  this.removeListener("end", onend);
48559
+ stop();
48542
48560
  reject(er);
48543
48561
  };
48544
48562
  const ondata = (value) => {
@@ -48550,6 +48568,7 @@ var require_minipass = __commonJS({
48550
48568
  const onend = () => {
48551
48569
  this.removeListener("error", onerr);
48552
48570
  this.removeListener("data", ondata);
48571
+ stop();
48553
48572
  resolve({ done: true });
48554
48573
  };
48555
48574
  const ondestroy = () => onerr(new Error("stream destroyed"));
@@ -48562,15 +48581,40 @@ var require_minipass = __commonJS({
48562
48581
  this.once("data", ondata);
48563
48582
  });
48564
48583
  };
48565
- return { next };
48584
+ return {
48585
+ next,
48586
+ throw: stop,
48587
+ return: stop,
48588
+ [ASYNCITERATOR]() {
48589
+ return this;
48590
+ }
48591
+ };
48566
48592
  }
48567
48593
  [ITERATOR]() {
48594
+ let stopped = false;
48595
+ const stop = () => {
48596
+ this.pause();
48597
+ this.removeListener(ERROR, stop);
48598
+ this.removeListener("end", stop);
48599
+ stopped = true;
48600
+ return { done: true };
48601
+ };
48568
48602
  const next = () => {
48603
+ if (stopped)
48604
+ return stop();
48569
48605
  const value = this.read();
48570
- const done = value === null;
48571
- return { value, done };
48606
+ return value === null ? stop() : { value };
48607
+ };
48608
+ this.once("end", stop);
48609
+ this.once(ERROR, stop);
48610
+ return {
48611
+ next,
48612
+ throw: stop,
48613
+ return: stop,
48614
+ [ITERATOR]() {
48615
+ return this;
48616
+ }
48572
48617
  };
48573
- return { next };
48574
48618
  }
48575
48619
  destroy(er) {
48576
48620
  if (this[DESTROYED]) {
@@ -71542,12 +71586,12 @@ var require_figures = __commonJS({
71542
71586
  var require_separator = __commonJS({
71543
71587
  "../../../../node_modules/.pnpm/inquirer@8.2.5/node_modules/inquirer/lib/objects/separator.js"(exports, module2) {
71544
71588
  "use strict";
71545
- var chalk = require_chalk();
71589
+ var chalk2 = require_chalk();
71546
71590
  var figures = require_figures();
71547
71591
  var Separator = class {
71548
71592
  constructor(line) {
71549
71593
  this.type = "separator";
71550
- this.line = chalk.dim(line || new Array(15).join(figures.line));
71594
+ this.line = chalk2.dim(line || new Array(15).join(figures.line));
71551
71595
  }
71552
71596
  toString() {
71553
71597
  return this.line;
@@ -92282,7 +92326,7 @@ var require_ora2 = __commonJS({
92282
92326
  "../../../../node_modules/.pnpm/ora@5.4.1/node_modules/ora/index.js"(exports, module2) {
92283
92327
  "use strict";
92284
92328
  var readline = require("readline");
92285
- var chalk = require_chalk();
92329
+ var chalk2 = require_chalk();
92286
92330
  var cliCursor = require_cli_cursor();
92287
92331
  var cliSpinners = require_cli_spinners();
92288
92332
  var logSymbols = require_browser2();
@@ -92478,7 +92522,7 @@ var require_ora2 = __commonJS({
92478
92522
  const { frames } = this.spinner;
92479
92523
  let frame = frames[this.frameIndex];
92480
92524
  if (this.color) {
92481
- frame = chalk[this.color](frame);
92525
+ frame = chalk2[this.color](frame);
92482
92526
  }
92483
92527
  this.frameIndex = ++this.frameIndex % frames.length;
92484
92528
  const fullPrefixText = typeof this.prefixText === "string" && this.prefixText !== "" ? this.prefixText + " " : "";
@@ -92725,7 +92769,7 @@ var require_base3 = __commonJS({
92725
92769
  defaults: require_defaults2(),
92726
92770
  clone: require_clone()
92727
92771
  };
92728
- var chalk = require_chalk();
92772
+ var chalk2 = require_chalk();
92729
92773
  var runAsync = require_run_async();
92730
92774
  var { filter, flatMap, share, take, takeUntil } = require_operators();
92731
92775
  var Choices = require_choices();
@@ -92743,7 +92787,7 @@ var require_base3 = __commonJS({
92743
92787
  filteringText: "",
92744
92788
  when: () => true,
92745
92789
  suffix: "",
92746
- prefix: chalk.green("?")
92790
+ prefix: chalk2.green("?")
92747
92791
  });
92748
92792
  if (!this.opt.name) {
92749
92793
  this.throwParamError("name");
@@ -92816,12 +92860,12 @@ var require_base3 = __commonJS({
92816
92860
  return value;
92817
92861
  }
92818
92862
  getQuestion() {
92819
- let message = (this.opt.prefix ? this.opt.prefix + " " : "") + chalk.bold(this.opt.message) + this.opt.suffix + chalk.reset(" ");
92863
+ let message = (this.opt.prefix ? this.opt.prefix + " " : "") + chalk2.bold(this.opt.message) + this.opt.suffix + chalk2.reset(" ");
92820
92864
  if (this.opt.default != null && this.status !== "touched" && this.status !== "answered") {
92821
92865
  if (this.opt.type === "password") {
92822
- message += chalk.italic.dim("[hidden] ");
92866
+ message += chalk2.italic.dim("[hidden] ");
92823
92867
  } else {
92824
- message += chalk.dim("(" + this.opt.default + ") ");
92868
+ message += chalk2.dim("(" + this.opt.default + ") ");
92825
92869
  }
92826
92870
  }
92827
92871
  return message;
@@ -92883,7 +92927,7 @@ var require_events = __commonJS({
92883
92927
  var require_paginator = __commonJS({
92884
92928
  "../../../../node_modules/.pnpm/inquirer@8.2.5/node_modules/inquirer/lib/utils/paginator.js"(exports, module2) {
92885
92929
  "use strict";
92886
- var chalk = require_chalk();
92930
+ var chalk2 = require_chalk();
92887
92931
  var Paginator = class {
92888
92932
  constructor(screen, options = {}) {
92889
92933
  const { isInfinite = true } = options;
@@ -92904,7 +92948,7 @@ var require_paginator = __commonJS({
92904
92948
  }
92905
92949
  const visibleLines = this.isInfinite ? this.getInfiniteLines(lines, active, pageSize) : this.getFiniteLines(lines, active, pageSize);
92906
92950
  this.lastIndex = active;
92907
- return visibleLines.join("\n") + "\n" + chalk.dim("(Move up and down to reveal more choices)");
92951
+ return visibleLines.join("\n") + "\n" + chalk2.dim("(Move up and down to reveal more choices)");
92908
92952
  }
92909
92953
  getInfiniteLines(lines, active, pageSize) {
92910
92954
  if (this.pointer === void 0) {
@@ -92960,7 +93004,7 @@ var require_incrementListIndex = __commonJS({
92960
93004
  var require_list2 = __commonJS({
92961
93005
  "../../../../node_modules/.pnpm/inquirer@8.2.5/node_modules/inquirer/lib/prompts/list.js"(exports, module2) {
92962
93006
  "use strict";
92963
- var chalk = require_chalk();
93007
+ var chalk2 = require_chalk();
92964
93008
  var figures = require_figures();
92965
93009
  var cliCursor = require_cli_cursor();
92966
93010
  var runAsync = require_run_async();
@@ -93009,10 +93053,10 @@ var require_list2 = __commonJS({
93009
93053
  render() {
93010
93054
  let message = this.getQuestion();
93011
93055
  if (this.firstRender) {
93012
- message += chalk.dim("(Use arrow keys)");
93056
+ message += chalk2.dim("(Use arrow keys)");
93013
93057
  }
93014
93058
  if (this.status === "answered") {
93015
- message += chalk.cyan(this.opt.choices.getChoice(this.selected).short);
93059
+ message += chalk2.cyan(this.opt.choices.getChoice(this.selected).short);
93016
93060
  } else {
93017
93061
  const choicesStr = listRender(this.opt.choices, this.selected);
93018
93062
  const indexPosition = this.opt.choices.indexOf(
@@ -93081,7 +93125,7 @@ var require_list2 = __commonJS({
93081
93125
  const isSelected = i - separatorOffset === pointer;
93082
93126
  let line = (isSelected ? figures.pointer + " " : " ") + choice.name;
93083
93127
  if (isSelected) {
93084
- line = chalk.cyan(line);
93128
+ line = chalk2.cyan(line);
93085
93129
  }
93086
93130
  output2 += line + " \n";
93087
93131
  });
@@ -93095,7 +93139,7 @@ var require_list2 = __commonJS({
93095
93139
  var require_input = __commonJS({
93096
93140
  "../../../../node_modules/.pnpm/inquirer@8.2.5/node_modules/inquirer/lib/prompts/input.js"(exports, module2) {
93097
93141
  "use strict";
93098
- var chalk = require_chalk();
93142
+ var chalk2 = require_chalk();
93099
93143
  var { map: map2, takeUntil } = require_operators();
93100
93144
  var Base = require_base3();
93101
93145
  var observe2 = require_events();
@@ -93125,10 +93169,10 @@ var require_input = __commonJS({
93125
93169
  if (transformer) {
93126
93170
  message += transformer(appendContent, this.answers, { isFinal });
93127
93171
  } else {
93128
- message += isFinal ? chalk.cyan(appendContent) : appendContent;
93172
+ message += isFinal ? chalk2.cyan(appendContent) : appendContent;
93129
93173
  }
93130
93174
  if (error) {
93131
- bottomContent = chalk.red(">> ") + error;
93175
+ bottomContent = chalk2.red(">> ") + error;
93132
93176
  }
93133
93177
  this.screen.render(message, bottomContent);
93134
93178
  }
@@ -93184,7 +93228,7 @@ var require_number = __commonJS({
93184
93228
  var require_confirm = __commonJS({
93185
93229
  "../../../../node_modules/.pnpm/inquirer@8.2.5/node_modules/inquirer/lib/prompts/confirm.js"(exports, module2) {
93186
93230
  "use strict";
93187
- var chalk = require_chalk();
93231
+ var chalk2 = require_chalk();
93188
93232
  var { take, takeUntil } = require_operators();
93189
93233
  var Base = require_base3();
93190
93234
  var observe2 = require_events();
@@ -93217,7 +93261,7 @@ var require_confirm = __commonJS({
93217
93261
  render(answer) {
93218
93262
  let message = this.getQuestion();
93219
93263
  if (typeof answer === "boolean") {
93220
- message += chalk.cyan(answer ? "Yes" : "No");
93264
+ message += chalk2.cyan(answer ? "Yes" : "No");
93221
93265
  } else {
93222
93266
  message += this.rl.line;
93223
93267
  }
@@ -93243,7 +93287,7 @@ var require_confirm = __commonJS({
93243
93287
  var require_rawlist = __commonJS({
93244
93288
  "../../../../node_modules/.pnpm/inquirer@8.2.5/node_modules/inquirer/lib/prompts/rawlist.js"(exports, module2) {
93245
93289
  "use strict";
93246
- var chalk = require_chalk();
93290
+ var chalk2 = require_chalk();
93247
93291
  var { map: map2, takeUntil } = require_operators();
93248
93292
  var Base = require_base3();
93249
93293
  var Separator = require_separator();
@@ -93297,7 +93341,7 @@ var require_rawlist = __commonJS({
93297
93341
  let message = this.getQuestion();
93298
93342
  let bottomContent = "";
93299
93343
  if (this.status === "answered") {
93300
- message += chalk.cyan(this.opt.choices.getChoice(this.selected).short);
93344
+ message += chalk2.cyan(this.opt.choices.getChoice(this.selected).short);
93301
93345
  } else {
93302
93346
  const choicesStr = renderChoices(this.opt.choices, this.selected);
93303
93347
  message += "\n" + this.paginator.paginate(choicesStr, this.selected, this.opt.pageSize);
@@ -93305,7 +93349,7 @@ var require_rawlist = __commonJS({
93305
93349
  }
93306
93350
  message += this.rl.line;
93307
93351
  if (error) {
93308
- bottomContent = "\n" + chalk.red(">> ") + error;
93352
+ bottomContent = "\n" + chalk2.red(">> ") + error;
93309
93353
  }
93310
93354
  this.screen.render(message, bottomContent);
93311
93355
  }
@@ -93372,7 +93416,7 @@ var require_rawlist = __commonJS({
93372
93416
  const index = i - separatorOffset;
93373
93417
  let display = index + 1 + ") " + choice.name;
93374
93418
  if (index === pointer) {
93375
- display = chalk.cyan(display);
93419
+ display = chalk2.cyan(display);
93376
93420
  }
93377
93421
  output2 += display;
93378
93422
  });
@@ -93386,7 +93430,7 @@ var require_rawlist = __commonJS({
93386
93430
  var require_expand2 = __commonJS({
93387
93431
  "../../../../node_modules/.pnpm/inquirer@8.2.5/node_modules/inquirer/lib/prompts/expand.js"(exports, module2) {
93388
93432
  "use strict";
93389
- var chalk = require_chalk();
93433
+ var chalk2 = require_chalk();
93390
93434
  var { map: map2, takeUntil } = require_operators();
93391
93435
  var Base = require_base3();
93392
93436
  var Separator = require_separator();
@@ -93429,7 +93473,7 @@ var require_expand2 = __commonJS({
93429
93473
  let message = this.getQuestion();
93430
93474
  let bottomContent = "";
93431
93475
  if (this.status === "answered") {
93432
- message += chalk.cyan(this.answer);
93476
+ message += chalk2.cyan(this.answer);
93433
93477
  } else if (this.status === "expanded") {
93434
93478
  const choicesStr = renderChoices(this.opt.choices, this.selectedKey);
93435
93479
  message += this.paginator.paginate(choicesStr, this.selectedKey, this.opt.pageSize);
@@ -93437,10 +93481,10 @@ var require_expand2 = __commonJS({
93437
93481
  }
93438
93482
  message += this.rl.line;
93439
93483
  if (error) {
93440
- bottomContent = chalk.red(">> ") + error;
93484
+ bottomContent = chalk2.red(">> ") + error;
93441
93485
  }
93442
93486
  if (hint) {
93443
- bottomContent = chalk.cyan(">> ") + hint;
93487
+ bottomContent = chalk2.cyan(">> ") + hint;
93444
93488
  }
93445
93489
  this.screen.render(message, bottomContent);
93446
93490
  }
@@ -93464,7 +93508,7 @@ var require_expand2 = __commonJS({
93464
93508
  }
93465
93509
  let choiceStr = choice.key + ") " + choice.name;
93466
93510
  if (this.selectedKey === choice.key) {
93467
- choiceStr = chalk.cyan(choiceStr);
93511
+ choiceStr = chalk2.cyan(choiceStr);
93468
93512
  }
93469
93513
  output2 += choiceStr;
93470
93514
  });
@@ -93550,7 +93594,7 @@ var require_expand2 = __commonJS({
93550
93594
  }
93551
93595
  let choiceStr = choice.key + ") " + choice.name;
93552
93596
  if (pointer === choice.key) {
93553
- choiceStr = chalk.cyan(choiceStr);
93597
+ choiceStr = chalk2.cyan(choiceStr);
93554
93598
  }
93555
93599
  output2 += choiceStr;
93556
93600
  });
@@ -93564,7 +93608,7 @@ var require_expand2 = __commonJS({
93564
93608
  var require_checkbox = __commonJS({
93565
93609
  "../../../../node_modules/.pnpm/inquirer@8.2.5/node_modules/inquirer/lib/prompts/checkbox.js"(exports, module2) {
93566
93610
  "use strict";
93567
- var chalk = require_chalk();
93611
+ var chalk2 = require_chalk();
93568
93612
  var cliCursor = require_cli_cursor();
93569
93613
  var figures = require_figures();
93570
93614
  var { map: map2, takeUntil } = require_operators();
@@ -93613,10 +93657,10 @@ var require_checkbox = __commonJS({
93613
93657
  let message = this.getQuestion();
93614
93658
  let bottomContent = "";
93615
93659
  if (!this.dontShowHints) {
93616
- message += "(Press " + chalk.cyan.bold("<space>") + " to select, " + chalk.cyan.bold("<a>") + " to toggle all, " + chalk.cyan.bold("<i>") + " to invert selection, and " + chalk.cyan.bold("<enter>") + " to proceed)";
93660
+ message += "(Press " + chalk2.cyan.bold("<space>") + " to select, " + chalk2.cyan.bold("<a>") + " to toggle all, " + chalk2.cyan.bold("<i>") + " to invert selection, and " + chalk2.cyan.bold("<enter>") + " to proceed)";
93617
93661
  }
93618
93662
  if (this.status === "answered") {
93619
- message += chalk.cyan(this.selection.join(", "));
93663
+ message += chalk2.cyan(this.selection.join(", "));
93620
93664
  } else {
93621
93665
  const choicesStr = renderChoices(this.opt.choices, this.pointer);
93622
93666
  const indexPosition = this.opt.choices.indexOf(
@@ -93639,7 +93683,7 @@ var require_checkbox = __commonJS({
93639
93683
  message += "\n" + this.paginator.paginate(choicesStr, realIndexPosition, this.opt.pageSize);
93640
93684
  }
93641
93685
  if (error) {
93642
- bottomContent = chalk.red(">> ") + error;
93686
+ bottomContent = chalk2.red(">> ") + error;
93643
93687
  }
93644
93688
  this.screen.render(message, bottomContent);
93645
93689
  }
@@ -93722,7 +93766,7 @@ var require_checkbox = __commonJS({
93722
93766
  } else {
93723
93767
  const line = getCheckbox(choice.checked) + " " + choice.name;
93724
93768
  if (i - separatorOffset === pointer) {
93725
- output2 += chalk.cyan(figures.pointer + line);
93769
+ output2 += chalk2.cyan(figures.pointer + line);
93726
93770
  } else {
93727
93771
  output2 += " " + line;
93728
93772
  }
@@ -93732,7 +93776,7 @@ var require_checkbox = __commonJS({
93732
93776
  return output2.replace(/\n$/, "");
93733
93777
  }
93734
93778
  function getCheckbox(checked) {
93735
- return checked ? chalk.green(figures.radioOn) : figures.radioOff;
93779
+ return checked ? chalk2.green(figures.radioOn) : figures.radioOff;
93736
93780
  }
93737
93781
  module2.exports = CheckboxPrompt;
93738
93782
  }
@@ -93742,7 +93786,7 @@ var require_checkbox = __commonJS({
93742
93786
  var require_password = __commonJS({
93743
93787
  "../../../../node_modules/.pnpm/inquirer@8.2.5/node_modules/inquirer/lib/prompts/password.js"(exports, module2) {
93744
93788
  "use strict";
93745
- var chalk = require_chalk();
93789
+ var chalk2 = require_chalk();
93746
93790
  var { map: map2, takeUntil } = require_operators();
93747
93791
  var Base = require_base3();
93748
93792
  var observe2 = require_events();
@@ -93775,15 +93819,15 @@ var require_password = __commonJS({
93775
93819
  message += this.getMaskedValue(this.rl.line || "");
93776
93820
  }
93777
93821
  if (error) {
93778
- bottomContent = "\n" + chalk.red(">> ") + error;
93822
+ bottomContent = "\n" + chalk2.red(">> ") + error;
93779
93823
  }
93780
93824
  this.screen.render(message, bottomContent);
93781
93825
  }
93782
93826
  getMaskedValue(value) {
93783
93827
  if (this.status === "answered") {
93784
- return this.opt.mask ? chalk.cyan(mask(value, this.opt.mask)) : chalk.italic.dim("[hidden]");
93828
+ return this.opt.mask ? chalk2.cyan(mask(value, this.opt.mask)) : chalk2.italic.dim("[hidden]");
93785
93829
  }
93786
- return this.opt.mask ? mask(value, this.opt.mask) : chalk.italic.dim("[input is hidden] ");
93830
+ return this.opt.mask ? mask(value, this.opt.mask) : chalk2.italic.dim("[input is hidden] ");
93787
93831
  }
93788
93832
  getSpinningValue(value) {
93789
93833
  return this.getMaskedValue(value);
@@ -103291,7 +103335,7 @@ var require_main = __commonJS({
103291
103335
  var require_editor = __commonJS({
103292
103336
  "../../../../node_modules/.pnpm/inquirer@8.2.5/node_modules/inquirer/lib/prompts/editor.js"(exports, module2) {
103293
103337
  "use strict";
103294
- var chalk = require_chalk();
103338
+ var chalk2 = require_chalk();
103295
103339
  var { editAsync } = require_main();
103296
103340
  var Base = require_base3();
103297
103341
  var observe2 = require_events();
@@ -103314,12 +103358,12 @@ var require_editor = __commonJS({
103314
103358
  let bottomContent = "";
103315
103359
  let message = this.getQuestion();
103316
103360
  if (this.status === "answered") {
103317
- message += chalk.dim("Received");
103361
+ message += chalk2.dim("Received");
103318
103362
  } else {
103319
- message += chalk.dim("Press <enter> to launch your preferred editor.");
103363
+ message += chalk2.dim("Press <enter> to launch your preferred editor.");
103320
103364
  }
103321
103365
  if (error) {
103322
- bottomContent = chalk.red(">> ") + error;
103366
+ bottomContent = chalk2.red(">> ") + error;
103323
103367
  }
103324
103368
  this.screen.render(message, bottomContent);
103325
103369
  }
@@ -103863,12 +103907,12 @@ var require_node7 = __commonJS({
103863
103907
  var require_separator2 = __commonJS({
103864
103908
  "../../../../node_modules/.pnpm/inquirer@8.1.3/node_modules/inquirer/lib/objects/separator.js"(exports, module2) {
103865
103909
  "use strict";
103866
- var chalk = require_chalk();
103910
+ var chalk2 = require_chalk();
103867
103911
  var figures = require_figures();
103868
103912
  var Separator = class {
103869
103913
  constructor(line) {
103870
103914
  this.type = "separator";
103871
- this.line = chalk.dim(line || new Array(15).join(figures.line));
103915
+ this.line = chalk2.dim(line || new Array(15).join(figures.line));
103872
103916
  }
103873
103917
  toString() {
103874
103918
  return this.line;
@@ -104857,7 +104901,7 @@ var require_base4 = __commonJS({
104857
104901
  defaults: require_defaults2(),
104858
104902
  clone: require_clone()
104859
104903
  };
104860
- var chalk = require_chalk();
104904
+ var chalk2 = require_chalk();
104861
104905
  var runAsync = require_run_async();
104862
104906
  var { filter, flatMap, share, take, takeUntil } = require_operators();
104863
104907
  var Choices = require_choices2();
@@ -104875,7 +104919,7 @@ var require_base4 = __commonJS({
104875
104919
  filteringText: "",
104876
104920
  when: () => true,
104877
104921
  suffix: "",
104878
- prefix: chalk.green("?")
104922
+ prefix: chalk2.green("?")
104879
104923
  });
104880
104924
  if (!this.opt.name) {
104881
104925
  this.throwParamError("name");
@@ -104948,12 +104992,12 @@ var require_base4 = __commonJS({
104948
104992
  return value;
104949
104993
  }
104950
104994
  getQuestion() {
104951
- let message = (this.opt.prefix ? this.opt.prefix + " " : "") + chalk.bold(this.opt.message) + this.opt.suffix + chalk.reset(" ");
104995
+ let message = (this.opt.prefix ? this.opt.prefix + " " : "") + chalk2.bold(this.opt.message) + this.opt.suffix + chalk2.reset(" ");
104952
104996
  if (this.opt.default != null && this.status !== "touched" && this.status !== "answered") {
104953
104997
  if (this.opt.type === "password") {
104954
- message += chalk.italic.dim("[hidden] ");
104998
+ message += chalk2.italic.dim("[hidden] ");
104955
104999
  } else {
104956
- message += chalk.dim("(" + this.opt.default + ") ");
105000
+ message += chalk2.dim("(" + this.opt.default + ") ");
104957
105001
  }
104958
105002
  }
104959
105003
  return message;
@@ -105048,7 +105092,7 @@ var require_paginator2 = __commonJS({
105048
105092
  sum: require_sum(),
105049
105093
  flatten: require_flatten()
105050
105094
  };
105051
- var chalk = require_chalk();
105095
+ var chalk2 = require_chalk();
105052
105096
  var Paginator = class {
105053
105097
  constructor(screen, options = {}) {
105054
105098
  const { isInfinite = true } = options;
@@ -105069,7 +105113,7 @@ var require_paginator2 = __commonJS({
105069
105113
  }
105070
105114
  const visibleLines = this.isInfinite ? this.getInfiniteLines(lines, active, pageSize) : this.getFiniteLines(lines, active, pageSize);
105071
105115
  this.lastIndex = active;
105072
- return visibleLines.join("\n") + "\n" + chalk.dim("(Move up and down to reveal more choices)");
105116
+ return visibleLines.join("\n") + "\n" + chalk2.dim("(Move up and down to reveal more choices)");
105073
105117
  }
105074
105118
  getInfiniteLines(lines, active, pageSize) {
105075
105119
  if (this.pointer === void 0) {
@@ -105130,7 +105174,7 @@ var require_list3 = __commonJS({
105130
105174
  findIndex: require_findIndex2(),
105131
105175
  isString: require_isString()
105132
105176
  };
105133
- var chalk = require_chalk();
105177
+ var chalk2 = require_chalk();
105134
105178
  var figures = require_figures();
105135
105179
  var cliCursor = require_cli_cursor();
105136
105180
  var runAsync = require_run_async();
@@ -105182,10 +105226,10 @@ var require_list3 = __commonJS({
105182
105226
  render() {
105183
105227
  let message = this.getQuestion();
105184
105228
  if (this.firstRender) {
105185
- message += chalk.dim("(Use arrow keys)");
105229
+ message += chalk2.dim("(Use arrow keys)");
105186
105230
  }
105187
105231
  if (this.status === "answered") {
105188
- message += chalk.cyan(this.opt.choices.getChoice(this.selected).short);
105232
+ message += chalk2.cyan(this.opt.choices.getChoice(this.selected).short);
105189
105233
  } else {
105190
105234
  const choicesStr = listRender(this.opt.choices, this.selected);
105191
105235
  const indexPosition = this.opt.choices.indexOf(
@@ -105254,7 +105298,7 @@ var require_list3 = __commonJS({
105254
105298
  const isSelected = i - separatorOffset === pointer;
105255
105299
  let line = (isSelected ? figures.pointer + " " : " ") + choice.name;
105256
105300
  if (isSelected) {
105257
- line = chalk.cyan(line);
105301
+ line = chalk2.cyan(line);
105258
105302
  }
105259
105303
  output2 += line + " \n";
105260
105304
  });
@@ -105268,7 +105312,7 @@ var require_list3 = __commonJS({
105268
105312
  var require_input2 = __commonJS({
105269
105313
  "../../../../node_modules/.pnpm/inquirer@8.1.3/node_modules/inquirer/lib/prompts/input.js"(exports, module2) {
105270
105314
  "use strict";
105271
- var chalk = require_chalk();
105315
+ var chalk2 = require_chalk();
105272
105316
  var { map: map2, takeUntil } = require_operators();
105273
105317
  var Base = require_base4();
105274
105318
  var observe2 = require_events2();
@@ -105298,10 +105342,10 @@ var require_input2 = __commonJS({
105298
105342
  if (transformer) {
105299
105343
  message += transformer(appendContent, this.answers, { isFinal });
105300
105344
  } else {
105301
- message += isFinal ? chalk.cyan(appendContent) : appendContent;
105345
+ message += isFinal ? chalk2.cyan(appendContent) : appendContent;
105302
105346
  }
105303
105347
  if (error) {
105304
- bottomContent = chalk.red(">> ") + error;
105348
+ bottomContent = chalk2.red(">> ") + error;
105305
105349
  }
105306
105350
  this.screen.render(message, bottomContent);
105307
105351
  }
@@ -105374,7 +105418,7 @@ var require_confirm2 = __commonJS({
105374
105418
  extend: require_extend(),
105375
105419
  isBoolean: require_isBoolean()
105376
105420
  };
105377
- var chalk = require_chalk();
105421
+ var chalk2 = require_chalk();
105378
105422
  var { take, takeUntil } = require_operators();
105379
105423
  var Base = require_base4();
105380
105424
  var observe2 = require_events2();
@@ -105407,7 +105451,7 @@ var require_confirm2 = __commonJS({
105407
105451
  render(answer) {
105408
105452
  let message = this.getQuestion();
105409
105453
  if (typeof answer === "boolean") {
105410
- message += chalk.cyan(answer ? "Yes" : "No");
105454
+ message += chalk2.cyan(answer ? "Yes" : "No");
105411
105455
  } else {
105412
105456
  message += this.rl.line;
105413
105457
  }
@@ -105438,7 +105482,7 @@ var require_rawlist2 = __commonJS({
105438
105482
  isNumber: require_isNumber(),
105439
105483
  findIndex: require_findIndex2()
105440
105484
  };
105441
- var chalk = require_chalk();
105485
+ var chalk2 = require_chalk();
105442
105486
  var { map: map2, takeUntil } = require_operators();
105443
105487
  var Base = require_base4();
105444
105488
  var Separator = require_separator2();
@@ -105493,7 +105537,7 @@ var require_rawlist2 = __commonJS({
105493
105537
  let message = this.getQuestion();
105494
105538
  let bottomContent = "";
105495
105539
  if (this.status === "answered") {
105496
- message += chalk.cyan(this.opt.choices.getChoice(this.selected).short);
105540
+ message += chalk2.cyan(this.opt.choices.getChoice(this.selected).short);
105497
105541
  } else {
105498
105542
  const choicesStr = renderChoices(this.opt.choices, this.selected);
105499
105543
  message += "\n" + this.paginator.paginate(choicesStr, this.selected, this.opt.pageSize);
@@ -105501,7 +105545,7 @@ var require_rawlist2 = __commonJS({
105501
105545
  }
105502
105546
  message += this.rl.line;
105503
105547
  if (error) {
105504
- bottomContent = "\n" + chalk.red(">> ") + error;
105548
+ bottomContent = "\n" + chalk2.red(">> ") + error;
105505
105549
  }
105506
105550
  this.screen.render(message, bottomContent);
105507
105551
  }
@@ -105559,7 +105603,7 @@ var require_rawlist2 = __commonJS({
105559
105603
  const index = i - separatorOffset;
105560
105604
  let display = index + 1 + ") " + choice.name;
105561
105605
  if (index === pointer) {
105562
- display = chalk.cyan(display);
105606
+ display = chalk2.cyan(display);
105563
105607
  }
105564
105608
  output2 += display;
105565
105609
  });
@@ -105734,7 +105778,7 @@ var require_expand3 = __commonJS({
105734
105778
  isNumber: require_isNumber(),
105735
105779
  findIndex: require_findIndex2()
105736
105780
  };
105737
- var chalk = require_chalk();
105781
+ var chalk2 = require_chalk();
105738
105782
  var { map: map2, takeUntil } = require_operators();
105739
105783
  var Base = require_base4();
105740
105784
  var Separator = require_separator2();
@@ -105777,7 +105821,7 @@ var require_expand3 = __commonJS({
105777
105821
  let message = this.getQuestion();
105778
105822
  let bottomContent = "";
105779
105823
  if (this.status === "answered") {
105780
- message += chalk.cyan(this.answer);
105824
+ message += chalk2.cyan(this.answer);
105781
105825
  } else if (this.status === "expanded") {
105782
105826
  const choicesStr = renderChoices(this.opt.choices, this.selectedKey);
105783
105827
  message += this.paginator.paginate(choicesStr, this.selectedKey, this.opt.pageSize);
@@ -105785,10 +105829,10 @@ var require_expand3 = __commonJS({
105785
105829
  }
105786
105830
  message += this.rl.line;
105787
105831
  if (error) {
105788
- bottomContent = chalk.red(">> ") + error;
105832
+ bottomContent = chalk2.red(">> ") + error;
105789
105833
  }
105790
105834
  if (hint) {
105791
- bottomContent = chalk.cyan(">> ") + hint;
105835
+ bottomContent = chalk2.cyan(">> ") + hint;
105792
105836
  }
105793
105837
  this.screen.render(message, bottomContent);
105794
105838
  }
@@ -105812,7 +105856,7 @@ var require_expand3 = __commonJS({
105812
105856
  }
105813
105857
  let choiceStr = choice.key + ") " + choice.name;
105814
105858
  if (this.selectedKey === choice.key) {
105815
- choiceStr = chalk.cyan(choiceStr);
105859
+ choiceStr = chalk2.cyan(choiceStr);
105816
105860
  }
105817
105861
  output2 += choiceStr;
105818
105862
  });
@@ -105901,7 +105945,7 @@ var require_expand3 = __commonJS({
105901
105945
  }
105902
105946
  let choiceStr = choice.key + ") " + choice.name;
105903
105947
  if (pointer === choice.key) {
105904
- choiceStr = chalk.cyan(choiceStr);
105948
+ choiceStr = chalk2.cyan(choiceStr);
105905
105949
  }
105906
105950
  output2 += choiceStr;
105907
105951
  });
@@ -105920,7 +105964,7 @@ var require_checkbox2 = __commonJS({
105920
105964
  map: require_map2(),
105921
105965
  isString: require_isString()
105922
105966
  };
105923
- var chalk = require_chalk();
105967
+ var chalk2 = require_chalk();
105924
105968
  var cliCursor = require_cli_cursor();
105925
105969
  var figures = require_figures();
105926
105970
  var { map: map2, takeUntil } = require_operators();
@@ -105969,10 +106013,10 @@ var require_checkbox2 = __commonJS({
105969
106013
  let message = this.getQuestion();
105970
106014
  let bottomContent = "";
105971
106015
  if (!this.spaceKeyPressed) {
105972
- message += "(Press " + chalk.cyan.bold("<space>") + " to select, " + chalk.cyan.bold("<a>") + " to toggle all, " + chalk.cyan.bold("<i>") + " to invert selection)";
106016
+ message += "(Press " + chalk2.cyan.bold("<space>") + " to select, " + chalk2.cyan.bold("<a>") + " to toggle all, " + chalk2.cyan.bold("<i>") + " to invert selection)";
105973
106017
  }
105974
106018
  if (this.status === "answered") {
105975
- message += chalk.cyan(this.selection.join(", "));
106019
+ message += chalk2.cyan(this.selection.join(", "));
105976
106020
  } else {
105977
106021
  const choicesStr = renderChoices(this.opt.choices, this.pointer);
105978
106022
  const indexPosition = this.opt.choices.indexOf(
@@ -105995,7 +106039,7 @@ var require_checkbox2 = __commonJS({
105995
106039
  message += "\n" + this.paginator.paginate(choicesStr, realIndexPosition, this.opt.pageSize);
105996
106040
  }
105997
106041
  if (error) {
105998
- bottomContent = chalk.red(">> ") + error;
106042
+ bottomContent = chalk2.red(">> ") + error;
105999
106043
  }
106000
106044
  this.screen.render(message, bottomContent);
106001
106045
  }
@@ -106079,7 +106123,7 @@ var require_checkbox2 = __commonJS({
106079
106123
  } else {
106080
106124
  const line = getCheckbox(choice.checked) + " " + choice.name;
106081
106125
  if (i - separatorOffset === pointer) {
106082
- output2 += chalk.cyan(figures.pointer + line);
106126
+ output2 += chalk2.cyan(figures.pointer + line);
106083
106127
  } else {
106084
106128
  output2 += " " + line;
106085
106129
  }
@@ -106089,7 +106133,7 @@ var require_checkbox2 = __commonJS({
106089
106133
  return output2.replace(/\n$/, "");
106090
106134
  }
106091
106135
  function getCheckbox(checked) {
106092
- return checked ? chalk.green(figures.radioOn) : figures.radioOff;
106136
+ return checked ? chalk2.green(figures.radioOn) : figures.radioOff;
106093
106137
  }
106094
106138
  module2.exports = CheckboxPrompt;
106095
106139
  }
@@ -106099,7 +106143,7 @@ var require_checkbox2 = __commonJS({
106099
106143
  var require_password2 = __commonJS({
106100
106144
  "../../../../node_modules/.pnpm/inquirer@8.1.3/node_modules/inquirer/lib/prompts/password.js"(exports, module2) {
106101
106145
  "use strict";
106102
- var chalk = require_chalk();
106146
+ var chalk2 = require_chalk();
106103
106147
  var { map: map2, takeUntil } = require_operators();
106104
106148
  var Base = require_base4();
106105
106149
  var observe2 = require_events2();
@@ -106132,15 +106176,15 @@ var require_password2 = __commonJS({
106132
106176
  message += this.getMaskedValue(this.rl.line || "");
106133
106177
  }
106134
106178
  if (error) {
106135
- bottomContent = "\n" + chalk.red(">> ") + error;
106179
+ bottomContent = "\n" + chalk2.red(">> ") + error;
106136
106180
  }
106137
106181
  this.screen.render(message, bottomContent);
106138
106182
  }
106139
106183
  getMaskedValue(value) {
106140
106184
  if (this.status === "answered") {
106141
- return this.opt.mask ? chalk.cyan(mask(value, this.opt.mask)) : chalk.italic.dim("[hidden]");
106185
+ return this.opt.mask ? chalk2.cyan(mask(value, this.opt.mask)) : chalk2.italic.dim("[hidden]");
106142
106186
  }
106143
- return this.opt.mask ? mask(value, this.opt.mask) : chalk.italic.dim("[input is hidden] ");
106187
+ return this.opt.mask ? mask(value, this.opt.mask) : chalk2.italic.dim("[input is hidden] ");
106144
106188
  }
106145
106189
  getSpinningValue(value) {
106146
106190
  return this.getMaskedValue(value);
@@ -106176,7 +106220,7 @@ var require_password2 = __commonJS({
106176
106220
  var require_editor2 = __commonJS({
106177
106221
  "../../../../node_modules/.pnpm/inquirer@8.1.3/node_modules/inquirer/lib/prompts/editor.js"(exports, module2) {
106178
106222
  "use strict";
106179
- var chalk = require_chalk();
106223
+ var chalk2 = require_chalk();
106180
106224
  var { editAsync } = require_main();
106181
106225
  var Base = require_base4();
106182
106226
  var observe2 = require_events2();
@@ -106199,12 +106243,12 @@ var require_editor2 = __commonJS({
106199
106243
  let bottomContent = "";
106200
106244
  let message = this.getQuestion();
106201
106245
  if (this.status === "answered") {
106202
- message += chalk.dim("Received");
106246
+ message += chalk2.dim("Received");
106203
106247
  } else {
106204
- message += chalk.dim("Press <enter> to launch your preferred editor.");
106248
+ message += chalk2.dim("Press <enter> to launch your preferred editor.");
106205
106249
  }
106206
106250
  if (error) {
106207
- bottomContent = chalk.red(">> ") + error;
106251
+ bottomContent = chalk2.red(">> ") + error;
106208
106252
  }
106209
106253
  this.screen.render(message, bottomContent);
106210
106254
  }
@@ -136282,12 +136326,14 @@ var require_node_env2 = __commonJS({
136282
136326
  "../../../toolkit/utils/dist/is/node-env.js"(exports) {
136283
136327
  "use strict";
136284
136328
  Object.defineProperty(exports, "__esModule", { value: true });
136285
- exports.isProdProfile = exports.isTest = exports.isProd = exports.isDev = void 0;
136286
- var isDev = () => process.env.NODE_ENV === "development";
136329
+ exports.isProdProfile = exports.isTest = exports.isProd = exports.isDev = exports.getNodeEnv = void 0;
136330
+ var getNodeEnv = () => process.env.NODE_ENV || "development";
136331
+ exports.getNodeEnv = getNodeEnv;
136332
+ var isDev = () => (0, exports.getNodeEnv)() === "development";
136287
136333
  exports.isDev = isDev;
136288
- var isProd = () => process.env.NODE_ENV === "production";
136334
+ var isProd = () => (0, exports.getNodeEnv)() === "production";
136289
136335
  exports.isProd = isProd;
136290
- var isTest = () => process.env.NODE_ENV === "test";
136336
+ var isTest = () => (0, exports.getNodeEnv)() === "test";
136291
136337
  exports.isTest = isTest;
136292
136338
  var isProdProfile = () => (0, exports.isProd)() && process.argv.includes("--profile");
136293
136339
  exports.isProdProfile = isProdProfile;
@@ -136376,7 +136422,7 @@ var require_is2 = __commonJS({
136376
136422
  return mod && mod.__esModule ? mod : { "default": mod };
136377
136423
  };
136378
136424
  Object.defineProperty(exports, "__esModule", { value: true });
136379
- exports.isFastRefresh = exports.isWorker = exports.isUseSSRBundle = exports.isSSR = exports.isEmpty = exports.isTypescript = exports.isDepExists = void 0;
136425
+ exports.isFastRefresh = exports.isUseSSRBundle = exports.isSSR = exports.isEmpty = exports.isTypescript = exports.isDepExists = void 0;
136380
136426
  var fs_1 = __importDefault(require("fs"));
136381
136427
  var path_1 = __importDefault(require("path"));
136382
136428
  var debug_1 = require_debug5();
@@ -136413,24 +136459,13 @@ var require_is2 = __commonJS({
136413
136459
  };
136414
136460
  exports.isSSR = isSSR;
136415
136461
  var isUseSSRBundle = (config) => {
136416
- const { output: output2, server } = config;
136417
- if (server.worker) {
136418
- return false;
136419
- }
136462
+ const { output: output2 } = config;
136420
136463
  if (output2 === null || output2 === void 0 ? void 0 : output2.ssg) {
136421
136464
  return true;
136422
136465
  }
136423
136466
  return (0, exports.isSSR)(config);
136424
136467
  };
136425
136468
  exports.isUseSSRBundle = isUseSSRBundle;
136426
- var isWorker = (config) => {
136427
- const { output: output2, server } = config;
136428
- if ((server === null || server === void 0 ? void 0 : server.worker) && ((output2 === null || output2 === void 0 ? void 0 : output2.ssg) || (0, exports.isSSR)(config))) {
136429
- return true;
136430
- }
136431
- return false;
136432
- };
136433
- exports.isWorker = isWorker;
136434
136469
  var isFastRefresh = () => (0, node_env_1.isDev)() && process.env.FAST_REFRESH !== "false";
136435
136470
  exports.isFastRefresh = isFastRefresh;
136436
136471
  __exportStar(require_node_env2(), exports);
@@ -136441,10 +136476,10 @@ var require_is2 = __commonJS({
136441
136476
 
136442
136477
  // ../../../toolkit/utils/dist/compatRequire.js
136443
136478
  var require_compatRequire2 = __commonJS({
136444
- "../../../toolkit/utils/dist/compatRequire.js"(exports) {
136479
+ "../../../toolkit/utils/dist/compatRequire.js"(exports, module2) {
136445
136480
  "use strict";
136446
136481
  Object.defineProperty(exports, "__esModule", { value: true });
136447
- exports.cleanRequireCache = exports.requireExistModule = exports.dynamicImport = exports.compatRequire = void 0;
136482
+ exports.deleteRequireCache = exports.cleanRequireCache = exports.requireExistModule = exports.dynamicImport = exports.compatRequire = void 0;
136448
136483
  var findExists_1 = require_findExists2();
136449
136484
  var compatRequire = (filePath, interop = true) => {
136450
136485
  const mod = require(filePath);
@@ -136471,6 +136506,15 @@ var require_compatRequire2 = __commonJS({
136471
136506
  });
136472
136507
  };
136473
136508
  exports.cleanRequireCache = cleanRequireCache;
136509
+ function deleteRequireCache(path9) {
136510
+ if (require.cache[path9]) {
136511
+ delete require.cache[path9];
136512
+ }
136513
+ if (module2.children) {
136514
+ module2.children = module2.children.filter((item) => item.filename !== path9);
136515
+ }
136516
+ }
136517
+ exports.deleteRequireCache = deleteRequireCache;
136474
136518
  }
136475
136519
  });
136476
136520
 
@@ -136492,7 +136536,7 @@ var require_constants6 = __commonJS({
136492
136536
  exports.SERVER_DIR = "server";
136493
136537
  exports.SHARED_DIR = "shared";
136494
136538
  exports.CONFIG_CACHE_DIR = "./node_modules/.cache/node-bundle-require";
136495
- exports.CONFIG_FILE_EXTENSIONS = [".js", ".ts", ".ejs", ".mjs"];
136539
+ exports.CONFIG_FILE_EXTENSIONS = [".js", ".ts", ".mjs"];
136496
136540
  exports.OUTPUT_CONFIG_FILE = "modern.config.json";
136497
136541
  exports.DEFAULT_SERVER_CONFIG = "modern.server-runtime.config";
136498
136542
  exports.ROUTE_MINIFEST_FILE = "routes-manifest.json";
@@ -136983,7 +137027,7 @@ var require_nodeEnv2 = __commonJS({
136983
137027
  });
136984
137028
  }
136985
137029
  exports.canUseNpm = canUseNpm3;
136986
- function canUseYarn3() {
137030
+ function canUseYarn2() {
136987
137031
  return __async(this, null, function* () {
136988
137032
  try {
136989
137033
  yield (0, compiled_1.execa)("yarn", ["--version"], { env: process.env });
@@ -136993,7 +137037,7 @@ var require_nodeEnv2 = __commonJS({
136993
137037
  }
136994
137038
  });
136995
137039
  }
136996
- exports.canUseYarn = canUseYarn3;
137040
+ exports.canUseYarn = canUseYarn2;
136997
137041
  function canUsePnpm3() {
136998
137042
  return __async(this, null, function* () {
136999
137043
  try {
@@ -140202,15 +140246,6 @@ function getPackageVersion(packageName, registry2) {
140202
140246
  spinner.stop();
140203
140247
  return stripAnsi2(result.stdout);
140204
140248
  }
140205
- if (yield (0, import_utils3.canUseYarn)()) {
140206
- const args = ["info", packageName, "version", "--silent"];
140207
- if (registry2) {
140208
- args.push(`--registry=${registry2}`);
140209
- }
140210
- const result = yield (0, import_utils3.execa)("yarn", args);
140211
- spinner.stop();
140212
- return stripAnsi2(result.stdout);
140213
- }
140214
140249
  if (yield (0, import_utils3.canUseNpm)()) {
140215
140250
  const args = ["view", packageName, "version"];
140216
140251
  if (registry2) {
@@ -140592,7 +140627,7 @@ function addManyFiles(config, projectPath, templatePath, renderString) {
140592
140627
  }
140593
140628
  function _addManyFiles() {
140594
140629
  _addManyFiles = _asyncToGenerator(function(config, projectPath, templatePath, renderString) {
140595
- var ref2, dest, templateFiles, filesAdded, _iteratorNormalCompletion, _didIteratorError, _iteratorError, _iterator, _step, templateFile, absTemplatePath, targetFile, fileCfg, addedPath, err;
140630
+ var _config_templateBase, dest, templateFiles, filesAdded, _iteratorNormalCompletion, _didIteratorError, _iteratorError, _iterator, _step, templateFile, absTemplatePath, targetFile, fileCfg, addedPath, err;
140596
140631
  return __generator6(this, function(_state) {
140597
140632
  switch (_state.label) {
140598
140633
  case 0:
@@ -140606,7 +140641,7 @@ function _addManyFiles() {
140606
140641
  config.templateFiles = config.templateFiles.map(function(templateFile2) {
140607
140642
  return import_path3.default.join(templatePath, templateFile2);
140608
140643
  });
140609
- config.templateBase = ((ref2 = config.templateBase) === null || ref2 === void 0 ? void 0 : ref2.startsWith(import_path3.default.sep)) ? config.templateBase : "".concat(import_path3.default.sep).concat(config.templateBase || "");
140644
+ config.templateBase = ((_config_templateBase = config.templateBase) === null || _config_templateBase === void 0 ? void 0 : _config_templateBase.startsWith(import_path3.default.sep)) ? config.templateBase : "".concat(import_path3.default.sep).concat(config.templateBase || "");
140610
140645
  templateFiles = import_utils5.globby.sync(config.templateFiles, {
140611
140646
  braceExpansion: false
140612
140647
  }).map(function(filePath) {
@@ -141759,10 +141794,10 @@ var PluginInputContext = /* @__PURE__ */ function() {
141759
141794
  var _this = this;
141760
141795
  var result = {};
141761
141796
  Object.keys(this.solutionSchema).forEach(function(key) {
141762
- var ref2 = _this.extendInputMap[key] || {
141797
+ var _ref = _this.extendInputMap[key] || {
141763
141798
  before: {},
141764
141799
  after: {}
141765
- }, before = ref2.before, after = ref2.after;
141800
+ }, before = _ref.before, after = _ref.after;
141766
141801
  Object.keys(before).forEach(function(beforeKey) {
141767
141802
  return result[beforeKey] = before[beforeKey];
141768
141803
  });
@@ -143704,7 +143739,7 @@ function _installPlugins() {
143704
143739
  2,
143705
143740
  Promise.all(plugins.map(function() {
143706
143741
  var _ref = _asyncToGenerator7(function(plugin) {
143707
- var ref2, name, version, pluginPath;
143742
+ var _getPackageInfo, name, version, pluginPath;
143708
143743
  return __generator12(this, function(_state2) {
143709
143744
  switch (_state2.label) {
143710
143745
  case 0:
@@ -143721,7 +143756,7 @@ function _installPlugins() {
143721
143756
  }
143722
143757
  ];
143723
143758
  case 1:
143724
- ref2 = (0, import_codesmith6.getPackageInfo)(plugin), name = ref2.name, version = ref2.version;
143759
+ _getPackageInfo = (0, import_codesmith6.getPackageInfo)(plugin), name = _getPackageInfo.name, version = _getPackageInfo.version;
143725
143760
  return [
143726
143761
  4,
143727
143762
  (0, import_codesmith6.downloadPackage)(name, version, {
@@ -144088,7 +144123,7 @@ var GeneratorPlugin = /* @__PURE__ */ function() {
144088
144123
  4,
144089
144124
  Promise.all(plugins.map(function() {
144090
144125
  var _ref = _asyncToGenerator8(function(plugin) {
144091
- var pkgJSON, ref2, name, pkgVersion, meta;
144126
+ var pkgJSON, _getPackageInfo, name, pkgVersion, meta;
144092
144127
  return __generator13(this, function(_state2) {
144093
144128
  switch (_state2.label) {
144094
144129
  case 0:
@@ -144108,7 +144143,7 @@ var GeneratorPlugin = /* @__PURE__ */ function() {
144108
144143
  4
144109
144144
  ];
144110
144145
  case 2:
144111
- ref2 = (0, import_codesmith7.getPackageInfo)(plugin), name = ref2.name, pkgVersion = ref2.version;
144146
+ _getPackageInfo = (0, import_codesmith7.getPackageInfo)(plugin), name = _getPackageInfo.name, pkgVersion = _getPackageInfo.version;
144112
144147
  return [
144113
144148
  4,
144114
144149
  getPackageMeta(name, pkgVersion, {
@@ -144307,10 +144342,10 @@ var GeneratorPlugin = /* @__PURE__ */ function() {
144307
144342
  try {
144308
144343
  for (var _iterator = this.plugins[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
144309
144344
  var info = _step.value;
144310
- var ref2;
144311
- if ((ref2 = info.context) === null || ref2 === void 0 ? void 0 : ref2.gitAPI.gitMessage) {
144312
- var ref1;
144313
- result = ((ref1 = info.context) === null || ref1 === void 0 ? void 0 : ref1.gitAPI.gitMessage) || "";
144345
+ var _info_context;
144346
+ if ((_info_context = info.context) === null || _info_context === void 0 ? void 0 : _info_context.gitAPI.gitMessage) {
144347
+ var _info_context1;
144348
+ result = ((_info_context1 = info.context) === null || _info_context1 === void 0 ? void 0 : _info_context1.gitAPI.gitMessage) || "";
144314
144349
  }
144315
144350
  }
144316
144351
  } catch (err) {
@@ -144335,7 +144370,7 @@ var GeneratorPlugin = /* @__PURE__ */ function() {
144335
144370
  value: function handleForged(solution, basePath, inputData, projectPath, generatorCore) {
144336
144371
  var _this = this;
144337
144372
  return _asyncToGenerator8(function() {
144338
- var generatorPlugin, restData, _iteratorNormalCompletion, _didIteratorError, _iteratorError, _iterator, _step, info, ref2, ref1, onForgedFunc, err, _iteratorNormalCompletion1, _didIteratorError1, _iteratorError1, _iterator1, _step1, info1, ref22, afterForged, err;
144373
+ var generatorPlugin, restData, _iteratorNormalCompletion, _didIteratorError, _iteratorError, _iterator, _step, info, _info_context, _info_context1, onForgedFunc, err, _iteratorNormalCompletion1, _didIteratorError1, _iteratorError1, _iterator1, _step1, info1, _info_context2, afterForged, err;
144339
144374
  return __generator13(this, function(_state) {
144340
144375
  switch (_state.label) {
144341
144376
  case 0:
@@ -144369,8 +144404,8 @@ var GeneratorPlugin = /* @__PURE__ */ function() {
144369
144404
  5
144370
144405
  ];
144371
144406
  info = _step.value;
144372
- (ref2 = info.context) === null || ref2 === void 0 ? void 0 : ref2.handlePrepareContext(generatorCore, solution, import_path8.default.join(basePath, projectPath), import_path8.default.join(info.templatePath, "templates"), restData);
144373
- onForgedFunc = (ref1 = info.context) === null || ref1 === void 0 ? void 0 : ref1.lifeCycleFuncMap[LifeCycle2.OnForged];
144407
+ (_info_context = info.context) === null || _info_context === void 0 ? void 0 : _info_context.handlePrepareContext(generatorCore, solution, import_path8.default.join(basePath, projectPath), import_path8.default.join(info.templatePath, "templates"), restData);
144408
+ onForgedFunc = (_info_context1 = info.context) === null || _info_context1 === void 0 ? void 0 : _info_context1.lifeCycleFuncMap[LifeCycle2.OnForged];
144374
144409
  if (!(onForgedFunc && (0, import_lodash10.isFunction)(onForgedFunc)))
144375
144410
  return [
144376
144411
  3,
@@ -144434,7 +144469,7 @@ var GeneratorPlugin = /* @__PURE__ */ function() {
144434
144469
  13
144435
144470
  ];
144436
144471
  info1 = _step1.value;
144437
- afterForged = (ref22 = info1.context) === null || ref22 === void 0 ? void 0 : ref22.lifeCycleFuncMap[LifeCycle2.AfterForged];
144472
+ afterForged = (_info_context2 = info1.context) === null || _info_context2 === void 0 ? void 0 : _info_context2.lifeCycleFuncMap[LifeCycle2.AfterForged];
144438
144473
  if (!(afterForged && (0, import_lodash10.isFunction)(afterForged)))
144439
144474
  return [
144440
144475
  3,
package/package.json CHANGED
@@ -11,7 +11,7 @@
11
11
  "modern",
12
12
  "modern.js"
13
13
  ],
14
- "version": "0.0.0-next-20230203070739",
14
+ "version": "0.0.0-next-20230206051444",
15
15
  "jsnext:source": "./src/index.ts",
16
16
  "main": "./dist/index.js",
17
17
  "files": [
@@ -26,16 +26,16 @@
26
26
  "@types/node": "^14",
27
27
  "jest": "^27",
28
28
  "typescript": "^4",
29
- "@modern-js/base-generator": "0.0.0-next-20230203070739",
30
- "@modern-js/generator-common": "0.0.0-next-20230203070739",
31
- "@modern-js/generator-utils": "0.0.0-next-20230203070739",
32
- "@modern-js/module-generator": "0.0.0-next-20230203070739",
33
- "@modern-js/monorepo-generator": "0.0.0-next-20230203070739",
34
- "@modern-js/generator-plugin": "0.0.0-next-20230203070739",
35
- "@modern-js/mwa-generator": "0.0.0-next-20230203070739",
36
- "@scripts/build": "0.0.0-next-20230203070739",
37
- "@scripts/jest-config": "0.0.0-next-20230203070739",
38
- "@modern-js/utils": "0.0.0-next-20230203070739"
29
+ "@modern-js/base-generator": "0.0.0-next-20230206051444",
30
+ "@modern-js/generator-common": "0.0.0-next-20230206051444",
31
+ "@modern-js/generator-plugin": "0.0.0-next-20230206051444",
32
+ "@modern-js/module-generator": "0.0.0-next-20230206051444",
33
+ "@modern-js/mwa-generator": "0.0.0-next-20230206051444",
34
+ "@modern-js/generator-utils": "0.0.0-next-20230206051444",
35
+ "@modern-js/monorepo-generator": "0.0.0-next-20230206051444",
36
+ "@modern-js/utils": "0.0.0-next-20230206051444",
37
+ "@scripts/build": "0.0.0-next-20230206051444",
38
+ "@scripts/jest-config": "0.0.0-next-20230206051444"
39
39
  },
40
40
  "sideEffects": false,
41
41
  "publishConfig": {