@cyberskill/shared 2.28.0 → 3.0.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.
Files changed (91) hide show
  1. package/dist/config/config.util.cjs +1 -1
  2. package/dist/config/config.util.js +24 -33
  3. package/dist/config/eslint/index.cjs +1 -1
  4. package/dist/config/eslint/index.d.ts +4 -0
  5. package/dist/config/eslint/index.js +4 -12
  6. package/dist/config/graphql-codegen/graphql-codegen.util.cjs +1 -1
  7. package/dist/config/graphql-codegen/graphql-codegen.util.js +28 -33
  8. package/dist/config/storybook/storybook.preview.cjs +1 -1
  9. package/dist/config/storybook/storybook.preview.js +10 -13
  10. package/dist/config/vitest/vitest.e2e.cjs +1 -1
  11. package/dist/config/vitest/vitest.e2e.js +1 -1
  12. package/dist/config/vitest/vitest.unit.cjs +1 -1
  13. package/dist/config/vitest/vitest.unit.js +19 -8
  14. package/dist/constant/common.cjs +1 -1
  15. package/dist/constant/common.js +1 -1
  16. package/dist/node/apollo-server/apollo-server.util.cjs +1 -1
  17. package/dist/node/apollo-server/apollo-server.util.js +21 -48
  18. package/dist/node/cli/index.cjs +2 -2
  19. package/dist/node/cli/index.js +109 -165
  20. package/dist/node/command/command.util.cjs +2 -2
  21. package/dist/node/command/command.util.js +135 -170
  22. package/dist/node/express/express.util.cjs +1 -1
  23. package/dist/node/express/express.util.js +39 -72
  24. package/dist/node/fs/fs.util.cjs +3 -3
  25. package/dist/node/fs/fs.util.js +45 -60
  26. package/dist/node/log/log.util.cjs +1 -1
  27. package/dist/node/log/log.util.js +29 -30
  28. package/dist/node/mongo/mongo.controller.cjs +1 -1
  29. package/dist/node/mongo/mongo.controller.js +531 -629
  30. package/dist/node/mongo/mongo.util.cjs +2 -2
  31. package/dist/node/mongo/mongo.util.js +280 -321
  32. package/dist/node/package/package.util.cjs +1 -1
  33. package/dist/node/package/package.util.js +197 -226
  34. package/dist/node/path/index.cjs +1 -1
  35. package/dist/node/path/index.js +26 -25
  36. package/dist/node/path/path.constant.cjs +1 -1
  37. package/dist/node/path/path.constant.d.ts +2 -0
  38. package/dist/node/path/path.constant.js +130 -150
  39. package/dist/node/storage/storage.util.cjs +1 -1
  40. package/dist/node/storage/storage.util.js +110 -158
  41. package/dist/node/upload/upload.util.cjs +1 -1
  42. package/dist/node/upload/upload.util.js +119 -150
  43. package/dist/node/ws/ts.util.cjs +1 -1
  44. package/dist/node/ws/ts.util.js +31 -54
  45. package/dist/react/apollo-client/apollo-client.component.cjs +1 -1
  46. package/dist/react/apollo-client/apollo-client.component.js +4 -4
  47. package/dist/react/apollo-client/apollo-client.util.cjs +1 -1
  48. package/dist/react/apollo-client/apollo-client.util.js +51 -58
  49. package/dist/react/apollo-client/links/upload.cjs +1 -1
  50. package/dist/react/apollo-client/links/upload.js +71 -74
  51. package/dist/react/apollo-client-nextjs/apollo-client-nextjs.util.cjs +1 -1
  52. package/dist/react/apollo-client-nextjs/apollo-client-nextjs.util.js +11 -18
  53. package/dist/react/apollo-error/apollo-error.component.cjs +1 -1
  54. package/dist/react/apollo-error/apollo-error.component.js +61 -23
  55. package/dist/react/apollo-error/apollo-error.module.scss.cjs +1 -1
  56. package/dist/react/apollo-error/apollo-error.module.scss.js +6 -6
  57. package/dist/react/apollo-error/apollo-error.test.unit.d.ts +1 -0
  58. package/dist/react/apollo-error/apollo-error.util.cjs +1 -1
  59. package/dist/react/apollo-error/apollo-error.util.js +6 -6
  60. package/dist/react/loading/loading.component.cjs +2 -2
  61. package/dist/react/loading/loading.component.js +30 -46
  62. package/dist/react/log/log.util.cjs +1 -1
  63. package/dist/react/log/log.util.js +4 -4
  64. package/dist/react/next-intl/next-intl.hoc.cjs +1 -1
  65. package/dist/react/next-intl/next-intl.hoc.js +13 -22
  66. package/dist/react/next-intl/next-intl.provider.cjs +1 -1
  67. package/dist/react/next-intl/next-intl.provider.js +7 -7
  68. package/dist/react/storage/storage.hook.cjs +1 -1
  69. package/dist/react/storage/storage.hook.js +43 -59
  70. package/dist/react/storage/storage.util.cjs +1 -1
  71. package/dist/react/storage/storage.util.js +28 -53
  72. package/dist/react/userback/userback.component.cjs +1 -1
  73. package/dist/react/userback/userback.component.js +18 -42
  74. package/dist/style.css +1 -1
  75. package/dist/util/common/common.util.cjs +1 -1
  76. package/dist/util/common/common.util.d.ts +2 -0
  77. package/dist/util/common/common.util.js +29 -37
  78. package/dist/util/index.cjs +1 -1
  79. package/dist/util/index.js +10 -9
  80. package/dist/util/object/object.util.cjs +1 -1
  81. package/dist/util/object/object.util.js +72 -76
  82. package/dist/util/string/index.cjs +1 -1
  83. package/dist/util/string/index.js +4 -3
  84. package/dist/util/string/string.util.cjs +1 -1
  85. package/dist/util/string/string.util.d.ts +12 -0
  86. package/dist/util/string/string.util.js +63 -44
  87. package/package.json +25 -16
  88. package/public/tsconfig.base.json +7 -3
  89. package/README.md +0 -470
  90. /package/dist/node_modules/.pnpm/{vitest@4.0.18_@types_node@25.3.0_jiti@2.6.1_jsdom@28.1.0_@noble_hashes@1.8.0__sass@1.97.3_tsx@4.21.0_yaml@2.8.2 → vitest@4.0.18_@types_node@25.3.3_jiti@2.6.1_jsdom@28.1.0_@noble_hashes@1.8.0__sass@1.97.3_tsx@4.21.0_yaml@2.8.2}/node_modules/vitest/dist/config.cjs +0 -0
  91. /package/dist/node_modules/.pnpm/{vitest@4.0.18_@types_node@25.3.0_jiti@2.6.1_jsdom@28.1.0_@noble_hashes@1.8.0__sass@1.97.3_tsx@4.21.0_yaml@2.8.2 → vitest@4.0.18_@types_node@25.3.3_jiti@2.6.1_jsdom@28.1.0_@noble_hashes@1.8.0__sass@1.97.3_tsx@4.21.0_yaml@2.8.2}/node_modules/vitest/dist/config.js +0 -0
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("@antfu/eslint-config"),i=require("./config.type.cjs"),o=require("./eslint/index.cjs"),_=require("./vitest/vitest.e2e.cjs"),l=require("./vitest/vitest.unit.cjs"),a=require("../util/object/object.util.cjs");var f=Object.getOwnPropertySymbols,y=Object.prototype.hasOwnProperty,u=Object.prototype.propertyIsEnumerable,E=(e,n)=>{var t={};for(var r in e)y.call(e,r)&&n.indexOf(r)<0&&(t[r]=e[r]);if(e!=null&&f)for(var r of f(e))n.indexOf(r)<0&&u.call(e,r)&&(t[r]=e[r]);return t};const p=(...e)=>{const t=a.deepMerge(...Array.isArray(o.default)?o.default:[o.default],...e),{ignores:r}=t,g=E(t,["ignores"]);return s({stylistic:{semi:!0,indent:4},formatters:!0,yaml:!1,react:!0},g,...Array.isArray(r)?[{ignores:r}]:[])},T={[i.E_ConfigType.ESLINT]:e=>p(e),[i.E_ConfigType.COMMITLINT]:e=>a.deepMerge(e),[i.E_ConfigType.LINT_STAGED]:e=>a.deepMerge(e),[i.E_ConfigType.VITEST_REACT_UNIT]:e=>l.vitestUnit(e),[i.E_ConfigType.VITEST_REACT_E2E]:e=>_.vitestE2E(e)};function d(e,...n){const t=T[e];if(!n||n.length===0)return t({});if(!t)throw new Error(`Unknown config type: ${e}`);return t(...n)}exports.mergeConfigs=d;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("@antfu/eslint-config"),n=require("./config.type.cjs"),i=require("./eslint/index.cjs"),f=require("./vitest/vitest.e2e.cjs"),g=require("./vitest/vitest.unit.cjs"),o=require("../util/object/object.util.cjs"),T=(...e)=>{const t=o.deepMerge(...Array.isArray(i.default)?i.default:[i.default],...e),{ignores:r,...s}=t;return u({stylistic:{semi:!0,indent:4},formatters:!0,yaml:!1,react:!0},s,...Array.isArray(r)?[{ignores:r}]:[])},a={[n.E_ConfigType.ESLINT]:e=>T(e),[n.E_ConfigType.COMMITLINT]:e=>o.deepMerge(e),[n.E_ConfigType.LINT_STAGED]:e=>o.deepMerge(e),[n.E_ConfigType.VITEST_REACT_UNIT]:e=>g.vitestUnit(e),[n.E_ConfigType.VITEST_REACT_E2E]:e=>f.vitestE2E(e)};function E(e,...t){const r=a[e];if(!t||t.length===0)return r({});if(!r)throw new Error(`Unknown config type: ${e}`);return r(...t)}exports.mergeConfigs=E;
@@ -1,24 +1,15 @@
1
- import s from "@antfu/eslint-config";
2
- import { E_ConfigType as o } from "./config.type.js";
3
- import i from "./eslint/index.js";
4
- import { vitestE2E as p } from "./vitest/vitest.e2e.js";
5
- import { vitestUnit as g } from "./vitest/vitest.unit.js";
6
- import { deepMerge as a } from "../util/object/object.util.js";
7
- var f = Object.getOwnPropertySymbols, l = Object.prototype.hasOwnProperty, E = Object.prototype.propertyIsEnumerable, _ = (r, n) => {
8
- var e = {};
9
- for (var t in r)
10
- l.call(r, t) && n.indexOf(t) < 0 && (e[t] = r[t]);
11
- if (r != null && f)
12
- for (var t of f(r))
13
- n.indexOf(t) < 0 && E.call(r, t) && (e[t] = r[t]);
14
- return e;
15
- };
16
- const y = (...r) => {
17
- const e = a(
18
- ...Array.isArray(i) ? i : [i],
1
+ import f from "@antfu/eslint-config";
2
+ import { E_ConfigType as n } from "./config.type.js";
3
+ import o from "./eslint/index.js";
4
+ import { vitestE2E as m } from "./vitest/vitest.e2e.js";
5
+ import { vitestUnit as a } from "./vitest/vitest.unit.js";
6
+ import { deepMerge as i } from "../util/object/object.util.js";
7
+ const E = (...r) => {
8
+ const e = i(
9
+ ...Array.isArray(o) ? o : [o],
19
10
  ...r
20
- ), { ignores: t } = e, m = _(e, ["ignores"]);
21
- return s(
11
+ ), { ignores: t, ...s } = e;
12
+ return f(
22
13
  {
23
14
  stylistic: {
24
15
  semi: !0,
@@ -28,24 +19,24 @@ const y = (...r) => {
28
19
  yaml: !1,
29
20
  react: !0
30
21
  },
31
- m,
22
+ s,
32
23
  ...Array.isArray(t) ? [{ ignores: t }] : []
33
24
  );
34
25
  }, T = {
35
- [o.ESLINT]: (r) => y(r),
36
- [o.COMMITLINT]: (r) => a(r),
37
- [o.LINT_STAGED]: (r) => a(r),
38
- [o.VITEST_REACT_UNIT]: (r) => g(r),
39
- [o.VITEST_REACT_E2E]: (r) => p(r)
26
+ [n.ESLINT]: (r) => E(r),
27
+ [n.COMMITLINT]: (r) => i(r),
28
+ [n.LINT_STAGED]: (r) => i(r),
29
+ [n.VITEST_REACT_UNIT]: (r) => a(r),
30
+ [n.VITEST_REACT_E2E]: (r) => m(r)
40
31
  };
41
- function w(r, ...n) {
42
- const e = T[r];
43
- if (!n || n.length === 0)
44
- return e({});
45
- if (!e)
32
+ function y(r, ...e) {
33
+ const t = T[r];
34
+ if (!e || e.length === 0)
35
+ return t({});
36
+ if (!t)
46
37
  throw new Error(`Unknown config type: ${r}`);
47
- return e(...n);
38
+ return t(...e);
48
39
  }
49
40
  export {
50
- w as mergeConfigs
41
+ y as mergeConfigs
51
42
  };
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const i=require("globals");function u(t){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const r in t)if(r!=="default"){const o=Object.getOwnPropertyDescriptor(t,r);Object.defineProperty(e,r,o.get?o:{enumerable:!0,get:()=>t[r]})}}return e.default=t,Object.freeze(e)}const n=u(i);var c=Object.defineProperty,a=Object.getOwnPropertySymbols,f=Object.prototype.hasOwnProperty,p=Object.prototype.propertyIsEnumerable,l=(t,e,r)=>e in t?c(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,s=(t,e)=>{for(var r in e||(e={}))f.call(e,r)&&l(t,r,e[r]);if(a)for(var r of a(e))p.call(e,r)&&l(t,r,e[r]);return t};const d=[{languageOptions:{globals:s(s({},n.node),n.browser)},rules:{"perfectionist/sort-imports":["error",{internalPattern:["^#.*","^@/.*"]}],"dot-notation":"off"},ignores:["**/node_modules/**","**/.git/**","build","dist",".agent"]}];exports.default=d;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const l=require("globals");function s(e){const o=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const n=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(o,t,n.get?n:{enumerable:!0,get:()=>e[t]})}}return o.default=e,Object.freeze(o)}const r=s(l),a=[{languageOptions:{globals:{...r.node,...r.browser}},rules:{"perfectionist/sort-imports":["error",{internalPattern:["^#.*","^@/.*"]}],"dot-notation":"off"},ignores:["**/node_modules/**","**/.git/**","build","dist",".agent"]}];exports.default=a;
@@ -113,6 +113,8 @@ declare const _default: {
113
113
  CookieStore: false;
114
114
  CookieStoreManager: false;
115
115
  CountQueuingStrategy: false;
116
+ crashReport: false;
117
+ CrashReportContext: false;
116
118
  createImageBitmap: false;
117
119
  CreateMonitor: false;
118
120
  Credential: false;
@@ -701,6 +703,7 @@ declare const _default: {
701
703
  Option: false;
702
704
  OrientationSensor: false;
703
705
  origin: false;
706
+ Origin: false;
704
707
  originAgentCluster: false;
705
708
  OscillatorNode: false;
706
709
  OTPCredential: false;
@@ -740,6 +743,7 @@ declare const _default: {
740
743
  PerformanceScriptTiming: false;
741
744
  PerformanceServerTiming: false;
742
745
  PerformanceTiming: false;
746
+ PerformanceTimingConfidence: false;
743
747
  PeriodicSyncManager: false;
744
748
  PeriodicWave: false;
745
749
  Permissions: false;
@@ -1,16 +1,8 @@
1
- import * as t from "globals";
2
- var l = Object.defineProperty, a = Object.getOwnPropertySymbols, i = Object.prototype.hasOwnProperty, p = Object.prototype.propertyIsEnumerable, n = (o, r, e) => r in o ? l(o, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : o[r] = e, s = (o, r) => {
3
- for (var e in r || (r = {}))
4
- i.call(r, e) && n(o, e, r[e]);
5
- if (a)
6
- for (var e of a(r))
7
- p.call(r, e) && n(o, e, r[e]);
8
- return o;
9
- };
10
- const f = [
1
+ import * as o from "globals";
2
+ const t = [
11
3
  {
12
4
  languageOptions: {
13
- globals: s(s({}, t.node), t.browser)
5
+ globals: { ...o.node, ...o.browser }
14
6
  },
15
7
  rules: {
16
8
  "perfectionist/sort-imports": ["error", {
@@ -22,5 +14,5 @@ const f = [
22
14
  }
23
15
  ];
24
16
  export {
25
- f as default
17
+ t as default
26
18
  };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("@eddeee888/gcg-typescript-resolver-files"),l=require("../env/env.util.cjs");var u=Object.defineProperty,f=Object.defineProperties,g=Object.getOwnPropertyDescriptors,i=Object.getOwnPropertySymbols,_=Object.prototype.hasOwnProperty,v=Object.prototype.propertyIsEnumerable,a=(t,e,r)=>e in t?u(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,n=(t,e)=>{for(var r in e||(e={}))_.call(e,r)&&a(t,r,e[r]);if(i)for(var r of i(e))v.call(e,r)&&a(t,r,e[r]);return t},d=(t,e)=>f(t,g(e));l.loadEnvFile();function m({uri:t,from:e,to:r,target:o="client"}){const s=o==="client",p=o==="server";return d(n({schema:t,ignoreNoDocuments:!0,overwrite:!0},s&&{documents:[e]}),{generates:n(n({},s&&{[r]:{preset:"client",presetConfig:{fragmentMasking:!1,persistedDocuments:!0},config:{useTypeImports:!0,namingConvention:"keep"}}}),p&&{[r]:c.defineConfig()})})}exports.createGraphqlCodegenConfig=m;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("@eddeee888/gcg-typescript-resolver-files"),c=require("../env/env.util.cjs");c.loadEnvFile();function u({uri:t,from:i,to:e,target:n="client"}){const r=n==="client",o=n==="server";return{schema:t,ignoreNoDocuments:!0,overwrite:!0,...r&&{documents:[i]},generates:{...r&&{[e]:{preset:"client",presetConfig:{fragmentMasking:!1,persistedDocuments:!0},config:{useTypeImports:!0,namingConvention:"keep"}}},...o&&{[e]:s.defineConfig()}}}}exports.createGraphqlCodegenConfig=u;
@@ -1,43 +1,38 @@
1
- import { defineConfig as c } from "@eddeee888/gcg-typescript-resolver-files";
2
- import { loadEnvFile as f } from "../env/env.util.js";
3
- var l = Object.defineProperty, u = Object.defineProperties, _ = Object.getOwnPropertyDescriptors, i = Object.getOwnPropertySymbols, m = Object.prototype.hasOwnProperty, v = Object.prototype.propertyIsEnumerable, p = (t, e, r) => e in t ? l(t, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : t[e] = r, o = (t, e) => {
4
- for (var r in e || (e = {}))
5
- m.call(e, r) && p(t, r, e[r]);
6
- if (i)
7
- for (var r of i(e))
8
- v.call(e, r) && p(t, r, e[r]);
9
- return t;
10
- }, g = (t, e) => u(t, _(e));
11
- f();
12
- function P({
1
+ import { defineConfig as s } from "@eddeee888/gcg-typescript-resolver-files";
2
+ import { loadEnvFile as c } from "../env/env.util.js";
3
+ c();
4
+ function p({
13
5
  uri: t,
14
- from: e,
15
- to: r,
6
+ from: o,
7
+ to: e,
16
8
  target: n = "client"
17
9
  }) {
18
- const s = n === "client", a = n === "server";
19
- return g(o({
10
+ const r = n === "client", i = n === "server";
11
+ return {
20
12
  schema: t,
21
13
  ignoreNoDocuments: !0,
22
- overwrite: !0
23
- }, s && { documents: [e] }), {
24
- generates: o(o({}, s && {
25
- [r]: {
26
- preset: "client",
27
- presetConfig: {
28
- fragmentMasking: !1,
29
- persistedDocuments: !0
30
- },
31
- config: {
32
- useTypeImports: !0,
33
- namingConvention: "keep"
14
+ overwrite: !0,
15
+ ...r && { documents: [o] },
16
+ generates: {
17
+ ...r && {
18
+ [e]: {
19
+ preset: "client",
20
+ presetConfig: {
21
+ fragmentMasking: !1,
22
+ persistedDocuments: !0
23
+ },
24
+ config: {
25
+ useTypeImports: !0,
26
+ namingConvention: "keep"
27
+ }
34
28
  }
29
+ },
30
+ ...i && {
31
+ [e]: s()
35
32
  }
36
- }), a && {
37
- [r]: c()
38
- })
39
- });
33
+ }
34
+ };
40
35
  }
41
36
  export {
42
- P as createGraphqlCodegenConfig
37
+ p as createGraphqlCodegenConfig
43
38
  };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});var l=Object.defineProperty,n=Object.defineProperties,p=Object.getOwnPropertyDescriptors,o=Object.getOwnPropertySymbols,c=Object.prototype.hasOwnProperty,f=Object.prototype.propertyIsEnumerable,s=(e,r,t)=>r in e?l(e,r,{enumerable:!0,configurable:!0,writable:!0,value:t}):e[r]=t,a=(e,r)=>{for(var t in r||(r={}))c.call(r,t)&&s(e,t,r[t]);if(o)for(var t of o(r))f.call(r,t)&&s(e,t,r[t]);return e},i=(e,r)=>n(e,p(r));function u(e){const r={parameters:{controls:{matchers:{color:/(background|color)$/i,date:/Date$/i}},backgrounds:{default:"light",values:[{name:"light",value:"#ffffff"},{name:"dark",value:"#333333"}]}}};return i(a(a({},r),e),{parameters:a(a({},r.parameters),e==null?void 0:e.parameters)})}exports.storybookPreview=u;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});function a(e){const r={parameters:{controls:{matchers:{color:/(background|color)$/i,date:/Date$/i}},backgrounds:{default:"light",values:[{name:"light",value:"#ffffff"},{name:"dark",value:"#333333"}]}}};return{...r,...e,parameters:{...r.parameters,...e?.parameters}}}exports.storybookPreview=a;
@@ -1,12 +1,4 @@
1
- var s = Object.defineProperty, n = Object.defineProperties, l = Object.getOwnPropertyDescriptors, o = Object.getOwnPropertySymbols, f = Object.prototype.hasOwnProperty, c = Object.prototype.propertyIsEnumerable, p = (e, r, a) => r in e ? s(e, r, { enumerable: !0, configurable: !0, writable: !0, value: a }) : e[r] = a, t = (e, r) => {
2
- for (var a in r || (r = {}))
3
- f.call(r, a) && p(e, a, r[a]);
4
- if (o)
5
- for (var a of o(r))
6
- c.call(r, a) && p(e, a, r[a]);
7
- return e;
8
- }, _ = (e, r) => n(e, l(r));
9
- function i(e) {
1
+ function a(e) {
10
2
  const r = {
11
3
  parameters: {
12
4
  controls: {
@@ -30,10 +22,15 @@ function i(e) {
30
22
  }
31
23
  }
32
24
  };
33
- return _(t(t({}, r), e), {
34
- parameters: t(t({}, r.parameters), e == null ? void 0 : e.parameters)
35
- });
25
+ return {
26
+ ...r,
27
+ ...e,
28
+ parameters: {
29
+ ...r.parameters,
30
+ ...e?.parameters
31
+ }
32
+ };
36
33
  }
37
34
  export {
38
- i as storybookPreview
35
+ a as storybookPreview
39
36
  };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("@vitejs/plugin-react-swc"),i=require("../../node_modules/.pnpm/vitest@4.0.18_@types_node@25.3.0_jiti@2.6.1_jsdom@28.1.0_@noble_hashes@1.8.0__sass@1.97.3_tsx@4.21.0_yaml@2.8.2/node_modules/vitest/dist/config.cjs"),o=require("../../util/object/object.util.cjs");function n(e){const r={plugins:[t()],test:{include:["**/*.test.e2e.?(c|m)[jt]s?(x)"],browser:{enabled:!0,provider:"playwright",instances:[{browser:"chromium"},{browser:"firefox"},{browser:"webkit"}]}}};return i.defineConfig(o.deepMerge(r,e))}exports.vitestE2E=n;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("@vitejs/plugin-react-swc"),i=require("../../node_modules/.pnpm/vitest@4.0.18_@types_node@25.3.3_jiti@2.6.1_jsdom@28.1.0_@noble_hashes@1.8.0__sass@1.97.3_tsx@4.21.0_yaml@2.8.2/node_modules/vitest/dist/config.cjs"),o=require("../../util/object/object.util.cjs");function n(e){const r={plugins:[t()],test:{include:["**/*.test.e2e.?(c|m)[jt]s?(x)"],browser:{enabled:!0,provider:"playwright",instances:[{browser:"chromium"},{browser:"firefox"},{browser:"webkit"}]}}};return i.defineConfig(o.deepMerge(r,e))}exports.vitestE2E=n;
@@ -1,5 +1,5 @@
1
1
  import t from "@vitejs/plugin-react-swc";
2
- import { defineConfig as o } from "../../node_modules/.pnpm/vitest@4.0.18_@types_node@25.3.0_jiti@2.6.1_jsdom@28.1.0_@noble_hashes@1.8.0__sass@1.97.3_tsx@4.21.0_yaml@2.8.2/node_modules/vitest/dist/config.js";
2
+ import { defineConfig as o } from "../../node_modules/.pnpm/vitest@4.0.18_@types_node@25.3.3_jiti@2.6.1_jsdom@28.1.0_@noble_hashes@1.8.0__sass@1.97.3_tsx@4.21.0_yaml@2.8.2/node_modules/vitest/dist/config.js";
3
3
  import { deepMerge as i } from "../../util/object/object.util.js";
4
4
  function m(e) {
5
5
  const r = {
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("@vitejs/plugin-react-swc"),n=require("../../node_modules/.pnpm/vitest@4.0.18_@types_node@25.3.0_jiti@2.6.1_jsdom@28.1.0_@noble_hashes@1.8.0__sass@1.97.3_tsx@4.21.0_yaml@2.8.2/node_modules/vitest/dist/config.cjs"),s=require("../../util/object/object.util.cjs");function r(e){const t={plugins:[i()],test:{globals:!0,environment:"jsdom",pool:"vmThreads",include:["**/*.test.unit.?(c|m)[jt]s?(x)"],setupFiles:["./vitest.unit.setup.ts"]}};return n.defineConfig(s.deepMerge(t,e))}exports.vitestUnit=r;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("@vitejs/plugin-react-swc"),i=require("../../node_modules/.pnpm/vitest@4.0.18_@types_node@25.3.3_jiti@2.6.1_jsdom@28.1.0_@noble_hashes@1.8.0__sass@1.97.3_tsx@4.21.0_yaml@2.8.2/node_modules/vitest/dist/config.cjs"),s=require("../../util/object/object.util.cjs");function n(e){const t={plugins:[r()],test:{globals:!0,environment:"jsdom",pool:"vmThreads",include:["**/*.test.unit.?(c|m)[jt]s?(x)"],setupFiles:["./vitest.unit.setup.ts"],coverage:{provider:"istanbul",reporter:["text","lcov"],reportsDirectory:"./coverage",thresholds:{statements:80,branches:80,functions:80,lines:80}}}};return i.defineConfig(s.deepMerge(t,e))}exports.vitestUnit=n;
@@ -1,18 +1,29 @@
1
- import i from "@vitejs/plugin-react-swc";
2
- import { defineConfig as o } from "../../node_modules/.pnpm/vitest@4.0.18_@types_node@25.3.0_jiti@2.6.1_jsdom@28.1.0_@noble_hashes@1.8.0__sass@1.97.3_tsx@4.21.0_yaml@2.8.2/node_modules/vitest/dist/config.js";
3
- import { deepMerge as n } from "../../util/object/object.util.js";
4
- function p(t) {
5
- const e = {
6
- plugins: [i()],
1
+ import r from "@vitejs/plugin-react-swc";
2
+ import { defineConfig as o } from "../../node_modules/.pnpm/vitest@4.0.18_@types_node@25.3.3_jiti@2.6.1_jsdom@28.1.0_@noble_hashes@1.8.0__sass@1.97.3_tsx@4.21.0_yaml@2.8.2/node_modules/vitest/dist/config.js";
3
+ import { deepMerge as s } from "../../util/object/object.util.js";
4
+ function p(e) {
5
+ const t = {
6
+ plugins: [r()],
7
7
  test: {
8
8
  globals: !0,
9
9
  environment: "jsdom",
10
10
  pool: "vmThreads",
11
11
  include: ["**/*.test.unit.?(c|m)[jt]s?(x)"],
12
- setupFiles: ["./vitest.unit.setup.ts"]
12
+ setupFiles: ["./vitest.unit.setup.ts"],
13
+ coverage: {
14
+ provider: "istanbul",
15
+ reporter: ["text", "lcov"],
16
+ reportsDirectory: "./coverage",
17
+ thresholds: {
18
+ statements: 80,
19
+ branches: 80,
20
+ functions: 80,
21
+ lines: 80
22
+ }
23
+ }
13
24
  }
14
25
  };
15
- return o(n(e, t));
26
+ return o(s(t, e));
16
27
  }
17
28
  export {
18
29
  p as vitestUnit
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=typeof window!="undefined";exports.IS_BROWSER=e;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=typeof window<"u";exports.IS_BROWSER=e;
@@ -1,4 +1,4 @@
1
- const e = typeof window != "undefined";
1
+ const e = typeof window < "u";
2
2
  export {
3
3
  e as IS_BROWSER
4
4
  };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const f=require("@apollo/server"),S=require("@apollo/server/plugin/drainHttpServer"),u=require("@apollo/server/plugin/landingPage/default"),_=require("../log/log.util.cjs");var P=Object.defineProperty,i=Object.getOwnPropertySymbols,g=Object.prototype.hasOwnProperty,h=Object.prototype.propertyIsEnumerable,v=(r,e,l)=>e in r?P(r,e,{enumerable:!0,configurable:!0,writable:!0,value:l}):r[e]=l,y=(r,e)=>{for(var l in e||(e={}))g.call(e,l)&&v(r,l,e[l]);if(i)for(var l of i(e))h.call(e,l)&&v(r,l,e[l]);return r},c=(r,e,l)=>new Promise((p,o)=>{var s=t=>{try{a(l.next(t))}catch(n){o(n)}},d=t=>{try{a(l.throw(t))}catch(n){o(n)}},a=t=>t.done?p(t.value):Promise.resolve(t.value).then(s,d);a((l=l.apply(r,e)).next())});function m(r){return new f.ApolloServer(y({schema:r.schema,plugins:[r.isDev?u.ApolloServerPluginLandingPageLocalDefault():u.ApolloServerPluginLandingPageProductionDefault(),S.ApolloServerPluginDrainHttpServer({httpServer:r.server}),...r.drainServer?[{serverWillStart(){return c(this,null,function*(){return{drainServer(){return c(this,null,function*(){var e;(e=r.drainServer)==null||e.call(r),_.log.info("Apollo Server drainServer hook called")})}}})}}]:[]]},r.isDev&&{introspection:!0,includeStacktraceInErrorResponses:!0}))}exports.createApolloServer=m;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("@apollo/server"),a=require("@apollo/server/plugin/drainHttpServer"),r=require("@apollo/server/plugin/landingPage/default"),n=require("../log/log.util.cjs");function t(e){return new l.ApolloServer({schema:e.schema,plugins:[e.isDev?r.ApolloServerPluginLandingPageLocalDefault():r.ApolloServerPluginLandingPageProductionDefault(),a.ApolloServerPluginDrainHttpServer({httpServer:e.server}),...e.drainServer?[{async serverWillStart(){return{async drainServer(){e.drainServer?.(),n.log.info("Apollo Server drainServer hook called")}}}}]:[]],...e.isDev&&{introspection:!0,includeStacktraceInErrorResponses:!0}})}exports.createApolloServer=t;
@@ -1,56 +1,29 @@
1
- import { ApolloServer as s } from "@apollo/server";
2
- import { ApolloServerPluginDrainHttpServer as m } from "@apollo/server/plugin/drainHttpServer";
3
- import { ApolloServerPluginLandingPageLocalDefault as d, ApolloServerPluginLandingPageProductionDefault as S } from "@apollo/server/plugin/landingPage/default";
4
- import { log as P } from "../log/log.util.js";
5
- var _ = Object.defineProperty, i = Object.getOwnPropertySymbols, h = Object.prototype.hasOwnProperty, y = Object.prototype.propertyIsEnumerable, u = (r, e, l) => e in r ? _(r, e, { enumerable: !0, configurable: !0, writable: !0, value: l }) : r[e] = l, g = (r, e) => {
6
- for (var l in e || (e = {}))
7
- h.call(e, l) && u(r, l, e[l]);
8
- if (i)
9
- for (var l of i(e))
10
- y.call(e, l) && u(r, l, e[l]);
11
- return r;
12
- }, v = (r, e, l) => new Promise((p, o) => {
13
- var c = (t) => {
14
- try {
15
- a(l.next(t));
16
- } catch (n) {
17
- o(n);
18
- }
19
- }, f = (t) => {
20
- try {
21
- a(l.throw(t));
22
- } catch (n) {
23
- o(n);
24
- }
25
- }, a = (t) => t.done ? p(t.value) : Promise.resolve(t.value).then(c, f);
26
- a((l = l.apply(r, e)).next());
27
- });
28
- function E(r) {
29
- return new s(g({
1
+ import { ApolloServer as e } from "@apollo/server";
2
+ import { ApolloServerPluginDrainHttpServer as l } from "@apollo/server/plugin/drainHttpServer";
3
+ import { ApolloServerPluginLandingPageLocalDefault as o, ApolloServerPluginLandingPageProductionDefault as n } from "@apollo/server/plugin/landingPage/default";
4
+ import { log as a } from "../log/log.util.js";
5
+ function c(r) {
6
+ return new e({
30
7
  schema: r.schema,
31
8
  plugins: [
32
- r.isDev ? d() : S(),
33
- m({ httpServer: r.server }),
9
+ r.isDev ? o() : n(),
10
+ l({ httpServer: r.server }),
34
11
  ...r.drainServer ? [{
35
- serverWillStart() {
36
- return v(this, null, function* () {
37
- return {
38
- drainServer() {
39
- return v(this, null, function* () {
40
- var e;
41
- (e = r.drainServer) == null || e.call(r), P.info("Apollo Server drainServer hook called");
42
- });
43
- }
44
- };
45
- });
12
+ async serverWillStart() {
13
+ return {
14
+ async drainServer() {
15
+ r.drainServer?.(), a.info("Apollo Server drainServer hook called");
16
+ }
17
+ };
46
18
  }
47
19
  }] : []
48
- ]
49
- }, r.isDev && {
50
- introspection: !0,
51
- includeStacktraceInErrorResponses: !0
52
- }));
20
+ ],
21
+ ...r.isDev && {
22
+ introspection: !0,
23
+ includeStacktraceInErrorResponses: !0
24
+ }
25
+ });
53
26
  }
54
27
  export {
55
- E as createApolloServer
28
+ c as createApolloServer
56
29
  };
@@ -1,3 +1,3 @@
1
1
  #!/usr/bin/env node
2
- "use strict";const d=require("node:process"),I=require("yargs/helpers"),T=require("yargs/yargs"),e=require("../command/command.util.cjs"),y=require("../package/package.util.cjs"),a=require("../fs/fs.util.cjs"),v=require("../path/path.util.cjs"),n=require("../path/path.constant.cjs"),u=require("../log/log.util.cjs"),f=require("../log/log.type.cjs");var t=(i,r,o)=>new Promise((l,p)=>{var A=c=>{try{m(o.next(c))}catch(g){p(g)}},S=c=>{try{m(o.throw(c))}catch(g){p(g)}},m=c=>c.done?l(c.value):Promise.resolve(c.value).then(A,S);m((o=o.apply(i,r)).next())});function M(){try{return JSON.parse(a.readFileSync(v.resolve(__dirname,"../../../package.json"),"utf-8")).version}catch(i){return"1.0.0"}}function E(){return t(this,null,function*(){a.pathExistsSync(n.PATH.TS_CONFIG)?yield e.runCommand("Performing TypeScript validation",yield n.command.typescriptCheck()):u.log.warn("No TypeScript configuration found. Skipping type check.")})}function C(i=!1){return t(this,null,function*(){const r=i?yield n.command.eslintFix():yield n.command.eslintCheck(),o=i?"Running ESLint with auto-fix":"Running ESLint check";try{yield e.runCommand(o,r,{timeout:6e4,throwOnError:!0})}catch(l){l.code==="ETIMEDOUT"||l.killed||l.signal==="SIGTERM"?(u.log.warn("Lint check timed out. Retrying with debug mode enabled..."),d.env.DEBUG="true",yield e.runCommand(`${o} (Debug Mode)`,r)):u.catchError(l)}})}function h(i,r){if(!r.length)return;const o=i==="Errors"?"red":"yellow";u.log.printBoxedLog(i==="Errors"?"✖ Errors":"⚠ Warnings",r,o)}function s(){return t(this,null,function*(){setTimeout(()=>t(null,null,function*(){const i=(yield e.getStoredErrorLists())||[],r=i.filter(l=>l.type===f.E_IssueType.Error),o=i.filter(l=>l.type===f.E_IssueType.Warning);!r.length&&!o.length?u.log.printBoxedLog("✔ NO ISSUES FOUND",[],"green"):(h("Warnings",o),h("Errors",r),r.length>0&&d.exit(1))}),0)})}function G(){return t(this,null,function*(){yield e.clearAllErrorLists();const i=yield y.getPackage({name:n.CYBERSKILL_PACKAGE_NAME});if(!i.success){u.log.error("Failed to retrieve package information. Aborting lint-staged.");return}i.result.isCurrentProject&&(yield e.runCommand(`Building package: ${n.CYBERSKILL_PACKAGE_NAME}`,yield n.command.build())),yield e.runCommand("Executing lint-staged",yield n.command.lintStaged()),s()})}function L(){return t(this,null,function*(){yield e.runCommand("Inspecting ESLint configuration",yield n.command.eslintInspect())})}function P(){return t(this,null,function*(){yield e.clearAllErrorLists(),yield E(),yield C(),s()})}function b(){return t(this,null,function*(){yield e.clearAllErrorLists(),yield E(),yield C(!0),s()})}function O(){return t(this,null,function*(){yield e.clearAllErrorLists(),yield e.runCommand("Validating commit message",yield n.command.commitLint()),s()})}function _(){return t(this,null,function*(){yield e.runCommand("Configuring Git hooks",yield n.command.configureGitHook()),a.removeSync(n.PATH.GIT_HOOK);const i=yield e.resolveCommands(n.createGitHooksConfig);a.writeFileSync(n.PATH.SIMPLE_GIT_HOOKS_JSON,JSON.stringify(i,null,4)),a.addGitIgnoreEntry(n.PATH.GIT_IGNORE,n.SIMPLE_GIT_HOOK_JSON),yield e.runCommand("Setting up simple-git-hooks",yield n.command.simpleGitHooks())})}function k(){return t(this,null,function*(){try{yield e.runCommand(`Checking for ${n.AG_KIT_PACKAGE_NAME}`,`pnpm list -g ${n.AG_KIT_PACKAGE_NAME}`)}catch(i){yield e.runCommand(`Installing ${n.AG_KIT_PACKAGE_NAME} globally`,`pnpm i -g ${n.AG_KIT_PACKAGE_NAME}`)}a.pathExistsSync(n.PATH.DOT_AGENT)?yield e.runCommand("Updating AI agent","ag-kit update -y"):yield e.runCommand("Initializing AI agent","ag-kit init"),a.addGitIgnoreEntry(n.PATH.GIT_IGNORE,n.DOT_AGENT)})}function D(){return t(this,null,function*(){yield y.installDependencies(),yield _()})}function N(){return t(this,null,function*(){a.removeSync(n.PATH.NODE_MODULES,n.PATH.PNPM_LOCK_YAML),yield e.runCommand("Pruning pnpm store",yield n.command.pnpmPruneStore()),yield e.runCommand("Clearing pnpm cache",yield n.command.pnpmCleanCache()),yield y.installDependencies(),yield _(),yield k()})}function R(){return t(this,null,function*(){yield e.runCommand("Inspecting project dependencies",yield n.command.nodeModulesInspect())})}function B(){return t(this,null,function*(){yield e.runCommand("Running unit tests",yield n.command.testUnit())})}function K(){return t(this,null,function*(){yield e.runCommand("Running end-to-end tests",yield n.command.testE2e())})}function w(i){return t(this,null,function*(){yield e.runCommand("Creating MongoDB migration",yield n.command.mongoMigrateCreate(i))})}function H(){return t(this,null,function*(){yield e.runCommand("Running MongoDB migrations",yield n.command.mongoMigrateUp())})}function q(){return t(this,null,function*(){yield e.runCommand("Rolling back MongoDB migration",yield n.command.mongoMigrateDown())})}function x(){return t(this,null,function*(){yield e.runCommand("Starting Storybook development server",yield n.command.storybookDev())})}function U(){return t(this,null,function*(){yield e.runCommand("Building Storybook",yield n.command.storybookBuild())})}t(null,null,function*(){try{yield T(I.hideBin(d.argv)).scriptName(n.CYBERSKILL_CLI).usage("$0 <command> [options]").command("ai:setup","Setup AI agent environment",k).command("lint","Check code for linting issues",P).command("lint:fix","Fix linting issues automatically",b).command("lint:inspect","View active ESLint configuration",L).command("lint-staged","Run lint checks on staged files",G).command("commitlint","Validate commit message format",O).command("ready","Initialize project and dependencies",D).command("reset","Reset the project and reinstall dependencies",N).command("inspect","Analyze installed project dependencies",R).command("test:unit","Run unit test suite",B).command("test:e2e","Run end-to-end test suite",K).command("mongo:migrate:create <name>","Create a MongoDB migration",i=>i.positional("name",{describe:"Migration name",type:"string"}),i=>t(null,null,function*(){if(!i.name){u.log.error("Migration name is required.");return}yield w(i.name)})).command("mongo:migrate:up","Apply all MongoDB migrations",H).command("mongo:migrate:down","Rollback last MongoDB migration",q).command("storybook:dev","Start Storybook development server",x).command("storybook:build","Build Storybook for production",U).demandCommand(1,"Please specify a valid command.").strict().help().alias("h","help").alias("v","version").version(M()).epilog(`💡 Tip: Use "--help" with any command to see options
3
- `).parse()}catch(i){u.catchError(i),d.exit(1)}});
2
+ "use strict";const s=require("node:process"),E=require("yargs/helpers"),C=require("yargs/yargs"),a=require("../command/command.util.cjs"),d=require("../package/package.util.cjs"),o=require("../fs/fs.util.cjs"),f=require("../path/path.util.cjs"),n=require("../path/path.constant.cjs"),r=require("../log/log.util.cjs"),u=require("../log/log.type.cjs");function h(){try{return JSON.parse(o.readFileSync(f.resolve(__dirname,"../../../package.json"),"utf-8")).version}catch{return"1.0.0"}}async function g(){o.pathExistsSync(n.PATH.TS_CONFIG)?await a.runCommand("Performing TypeScript validation",await n.command.typescriptCheck()):r.log.warn("No TypeScript configuration found. Skipping type check.")}async function p(t=!1){const i=t?await n.command.eslintFix():await n.command.eslintCheck(),c=t?"Running ESLint with auto-fix":"Running ESLint check";try{await a.runCommand(c,i,{timeout:6e4,throwOnError:!0})}catch(e){e.code==="ETIMEDOUT"||e.killed||e.signal==="SIGTERM"?(r.log.warn("Lint check timed out. Retrying with debug mode enabled..."),s.env.DEBUG="true",await a.runCommand(`${c} (Debug Mode)`,i)):r.catchError(e)}}function l(t,i){if(!i.length)return;const c=t==="Errors"?"red":"yellow";r.log.printBoxedLog(t==="Errors"?"✖ Errors":"⚠ Warnings",i,c)}async function m(){setTimeout(async()=>{const t=await a.getStoredErrorLists()||[],i=t.filter(e=>e.type===u.E_IssueType.Error),c=t.filter(e=>e.type===u.E_IssueType.Warning);!i.length&&!c.length?r.log.printBoxedLog("✔ NO ISSUES FOUND",[],"green"):(l("Warnings",c),l("Errors",i),i.length>0&&s.exit(1))},0)}async function k(){await a.clearAllErrorLists();const t=await d.getPackage({name:n.CYBERSKILL_PACKAGE_NAME});if(!t.success){r.log.error("Failed to retrieve package information. Aborting lint-staged.");return}t.result.isCurrentProject&&await a.runCommand(`Building package: ${n.CYBERSKILL_PACKAGE_NAME}`,await n.command.build()),await a.runCommand("Executing lint-staged",await n.command.lintStaged()),m()}async function A(){await a.runCommand("Inspecting ESLint configuration",await n.command.eslintInspect())}async function S(){await a.clearAllErrorLists(),await g(),await p(),m()}async function _(){await a.clearAllErrorLists(),await g(),await p(!0),m()}async function I(){await a.clearAllErrorLists(),await a.runCommand("Validating commit message",await n.command.commitLint()),m()}async function w(){await a.runCommand("Configuring Git hooks",await n.command.configureGitHook()),o.removeSync(n.PATH.GIT_HOOK);const t=await a.resolveCommands(n.createGitHooksConfig);o.writeFileSync(n.PATH.SIMPLE_GIT_HOOKS_JSON,JSON.stringify(t,null,4)),o.addGitIgnoreEntry(n.PATH.GIT_IGNORE,n.SIMPLE_GIT_HOOK_JSON),await a.runCommand("Setting up simple-git-hooks",await n.command.simpleGitHooks())}async function y(){try{await a.runCommand(`Checking for ${n.AG_KIT_PACKAGE_NAME}`,`pnpm list -g ${n.AG_KIT_PACKAGE_NAME}`)}catch{await a.runCommand(`Installing ${n.AG_KIT_PACKAGE_NAME} globally`,`pnpm i -g ${n.AG_KIT_PACKAGE_NAME}`)}o.pathExistsSync(n.PATH.DOT_AGENT)?await a.runCommand("Updating AI agent","ag-kit update -y"):await a.runCommand("Initializing AI agent","ag-kit init"),o.addGitIgnoreEntry(n.PATH.GIT_EXCLUDE,n.DOT_AGENT)}async function T(){await d.installDependencies(),await w()}async function M(){o.removeSync(n.PATH.NODE_MODULES,n.PATH.PNPM_LOCK_YAML),await a.runCommand("Pruning pnpm store",await n.command.pnpmPruneStore()),await a.runCommand("Clearing pnpm cache",await n.command.pnpmCleanCache()),await d.installDependencies(),await w(),await y()}async function L(){await a.runCommand("Inspecting project dependencies",await n.command.nodeModulesInspect())}async function G(){await a.runCommand("Running unit tests",await n.command.testUnit())}async function P(){await a.runCommand("Running end-to-end tests",await n.command.testE2e())}async function b(t){await a.runCommand("Creating MongoDB migration",await n.command.mongoMigrateCreate(t))}async function v(){await a.runCommand("Running MongoDB migrations",await n.command.mongoMigrateUp())}async function D(){await a.runCommand("Rolling back MongoDB migration",await n.command.mongoMigrateDown())}async function O(){await a.runCommand("Starting Storybook development server",await n.command.storybookDev())}async function N(){await a.runCommand("Building Storybook",await n.command.storybookBuild())}(async()=>{try{await C(E.hideBin(s.argv)).scriptName(n.CYBERSKILL_CLI).usage("$0 <command> [options]").command("ai:setup","Setup AI agent environment",y).command("lint","Check code for linting issues",S).command("lint:fix","Fix linting issues automatically",_).command("lint:inspect","View active ESLint configuration",A).command("lint-staged","Run lint checks on staged files",k).command("commitlint","Validate commit message format",I).command("ready","Initialize project and dependencies",T).command("reset","Reset the project and reinstall dependencies",M).command("inspect","Analyze installed project dependencies",L).command("test:unit","Run unit test suite",G).command("test:e2e","Run end-to-end test suite",P).command("mongo:migrate:create <name>","Create a MongoDB migration",t=>t.positional("name",{describe:"Migration name",type:"string"}),async t=>{if(!t.name){r.log.error("Migration name is required.");return}await b(t.name)}).command("mongo:migrate:up","Apply all MongoDB migrations",v).command("mongo:migrate:down","Rollback last MongoDB migration",D).command("storybook:dev","Start Storybook development server",O).command("storybook:build","Build Storybook for production",N).demandCommand(1,"Please specify a valid command.").strict().help().alias("h","help").alias("v","version").version(h()).epilog(`💡 Tip: Use "--help" with any command to see options
3
+ `).parse()}catch(t){r.catchError(t),s.exit(1)}})();