@cyberskill/shared 1.14.0 → 1.16.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 (135) hide show
  1. package/dist/commands.cjs +1 -1
  2. package/dist/commands.d.cts +1 -0
  3. package/dist/commands.d.ts +1 -0
  4. package/dist/commands.js +1 -1
  5. package/dist/components/react/index.d.cts +2 -0
  6. package/dist/components/react/index.d.ts +2 -0
  7. package/dist/components/react/loading/index.d.cts +11 -0
  8. package/dist/components/react/loading/index.d.ts +11 -0
  9. package/dist/components/react/loading/loading.module.d.cts +2 -0
  10. package/dist/components/react/loading/loading.module.d.ts +2 -0
  11. package/dist/configs/commitlint/base.d.cts +5 -0
  12. package/dist/configs/commitlint/base.d.ts +5 -0
  13. package/dist/configs/eslint/base.d.cts +1154 -0
  14. package/dist/configs/eslint/base.d.ts +1154 -0
  15. package/dist/configs/eslint/nestjs.d.cts +1156 -0
  16. package/dist/configs/eslint/nestjs.d.ts +1156 -0
  17. package/dist/configs/eslint/nextjs.d.cts +1156 -0
  18. package/dist/configs/eslint/nextjs.d.ts +1156 -0
  19. package/dist/configs/eslint/nodejs.d.cts +1156 -0
  20. package/dist/configs/eslint/nodejs.d.ts +1156 -0
  21. package/dist/configs/eslint/vite-react.d.cts +1157 -0
  22. package/dist/configs/eslint/vite-react.d.ts +1157 -0
  23. package/dist/configs/graphql/graphql-codegen.d.cts +8 -0
  24. package/dist/configs/graphql/graphql-codegen.d.ts +8 -0
  25. package/dist/configs/graphql/index.d.cts +5 -0
  26. package/dist/configs/graphql/index.d.ts +5 -0
  27. package/dist/configs/i18n/react/i18next.d.cts +6 -0
  28. package/dist/configs/i18n/react/i18next.d.ts +6 -0
  29. package/dist/configs/i18n/react/index.d.cts +2 -0
  30. package/dist/configs/i18n/react/index.d.ts +2 -0
  31. package/dist/configs/index.cjs +1 -1
  32. package/dist/configs/index.d.cts +9 -0
  33. package/dist/configs/index.d.ts +9 -0
  34. package/dist/configs/index.js +1 -1
  35. package/dist/configs/lint-staged/base.d.cts +5 -0
  36. package/dist/configs/lint-staged/base.d.ts +5 -0
  37. package/dist/configs/vitest/react/e2e.d.cts +6 -0
  38. package/dist/configs/vitest/react/e2e.d.ts +6 -0
  39. package/dist/configs/vitest/react/unit.d.cts +6 -0
  40. package/dist/configs/vitest/react/unit.d.ts +6 -0
  41. package/dist/configs/vitest/react/unit.setup.d.cts +2 -0
  42. package/dist/configs/vitest/react/unit.setup.d.ts +2 -0
  43. package/dist/constants/dirname.d.cts +3 -0
  44. package/dist/constants/dirname.d.ts +3 -0
  45. package/dist/constants/index.d.cts +2 -0
  46. package/dist/constants/index.d.ts +2 -0
  47. package/dist/constants/response-status.d.cts +252 -0
  48. package/dist/constants/response-status.d.ts +252 -0
  49. package/dist/contexts/react/index.d.cts +4 -0
  50. package/dist/contexts/react/index.d.ts +4 -0
  51. package/dist/contexts/react/loading.d.cts +7 -0
  52. package/dist/contexts/react/loading.d.ts +7 -0
  53. package/dist/controllers/index.cjs +1 -1
  54. package/dist/controllers/index.d.cts +5 -0
  55. package/dist/controllers/index.d.ts +5 -0
  56. package/dist/controllers/index.js +1 -1
  57. package/dist/controllers/migration.d.cts +55 -0
  58. package/dist/controllers/migration.d.ts +55 -0
  59. package/dist/controllers/mongoose.cjs +1 -1
  60. package/dist/controllers/mongoose.d.cts +25 -0
  61. package/dist/controllers/mongoose.d.ts +25 -0
  62. package/dist/controllers/mongoose.js +1 -1
  63. package/dist/hooks/react/index.cjs +1 -1
  64. package/dist/hooks/react/index.d.cts +6 -0
  65. package/dist/hooks/react/index.d.ts +6 -0
  66. package/dist/hooks/react/index.js +1 -1
  67. package/dist/hooks/react/use-loading.d.cts +7 -0
  68. package/dist/hooks/react/use-loading.d.ts +7 -0
  69. package/dist/hooks/react/use-storage.cjs +1 -1
  70. package/dist/hooks/react/use-storage.d.cts +5 -0
  71. package/dist/hooks/react/use-storage.d.ts +5 -0
  72. package/dist/hooks/react/use-storage.js +1 -1
  73. package/dist/index.cjs +1 -1
  74. package/dist/index.d.cts +32 -716
  75. package/dist/index.d.ts +32 -716
  76. package/dist/index.js +1 -1
  77. package/dist/providers/react/apollo-client.d.cts +11 -0
  78. package/dist/providers/react/apollo-client.d.ts +11 -0
  79. package/dist/providers/react/index.d.cts +6 -0
  80. package/dist/providers/react/index.d.ts +6 -0
  81. package/dist/providers/react/loading.d.cts +10 -0
  82. package/dist/providers/react/loading.d.ts +10 -0
  83. package/dist/typescript/command.cjs +1 -1
  84. package/dist/typescript/command.d.cts +39 -0
  85. package/dist/typescript/command.d.ts +39 -0
  86. package/dist/typescript/command.js +1 -1
  87. package/dist/typescript/config.d.cts +5 -0
  88. package/dist/typescript/config.d.ts +5 -0
  89. package/dist/typescript/index.cjs +1 -1
  90. package/dist/typescript/index.d.cts +10 -0
  91. package/dist/typescript/index.d.ts +10 -0
  92. package/dist/typescript/index.js +1 -1
  93. package/dist/typescript/log.d.cts +10 -0
  94. package/dist/typescript/log.d.ts +10 -0
  95. package/dist/typescript/mongoose.d.cts +163 -0
  96. package/dist/typescript/mongoose.d.ts +163 -0
  97. package/dist/typescript/react.d.cts +26 -0
  98. package/dist/typescript/react.d.ts +26 -0
  99. package/dist/typescript/serializer.d.cts +6 -0
  100. package/dist/typescript/serializer.d.ts +6 -0
  101. package/dist/utils/command-error.cjs +1 -1
  102. package/dist/utils/command-error.d.cts +15 -0
  103. package/dist/utils/command-error.d.ts +15 -0
  104. package/dist/utils/command-error.js +1 -1
  105. package/dist/utils/command-log.cjs +1 -1
  106. package/dist/utils/command-log.d.cts +3 -0
  107. package/dist/utils/command-log.d.ts +3 -0
  108. package/dist/utils/command-log.js +1 -1
  109. package/dist/utils/command-spinner.cjs +1 -1
  110. package/dist/utils/command-spinner.d.cts +11 -0
  111. package/dist/utils/command-spinner.d.ts +11 -0
  112. package/dist/utils/command-spinner.js +1 -1
  113. package/dist/utils/command.cjs +1 -1
  114. package/dist/utils/command.d.cts +5 -0
  115. package/dist/utils/command.d.ts +5 -0
  116. package/dist/utils/command.js +1 -1
  117. package/dist/utils/index.cjs +1 -1
  118. package/dist/utils/index.d.cts +26 -0
  119. package/dist/utils/index.d.ts +26 -0
  120. package/dist/utils/index.js +1 -1
  121. package/dist/utils/log.d.cts +5 -0
  122. package/dist/utils/log.d.ts +5 -0
  123. package/dist/utils/mongoose.d.cts +34 -0
  124. package/dist/utils/mongoose.d.ts +34 -0
  125. package/dist/utils/npm-package.cjs +1 -1
  126. package/dist/utils/npm-package.d.cts +16 -0
  127. package/dist/utils/npm-package.d.ts +16 -0
  128. package/dist/utils/npm-package.js +1 -1
  129. package/dist/utils/serializer.d.cts +5 -0
  130. package/dist/utils/serializer.d.ts +5 -0
  131. package/dist/utils/storage.d.cts +12 -0
  132. package/dist/utils/storage.d.ts +12 -0
  133. package/dist/utils/validate.d.cts +33 -0
  134. package/dist/utils/validate.d.ts +33 -0
  135. package/package.json +23 -1
@@ -0,0 +1,11 @@
1
+ import * as react_jsx_runtime from 'react/jsx-runtime';
2
+ import { I_ApolloOptions, T_Children } from '../../typescript/react.cjs';
3
+ import '@apollo/client';
4
+ import 'react';
5
+
6
+ declare function ApolloProvider({ options, children }: {
7
+ options: I_ApolloOptions;
8
+ children: T_Children;
9
+ }): react_jsx_runtime.JSX.Element;
10
+
11
+ export { ApolloProvider };
@@ -0,0 +1,11 @@
1
+ import * as react_jsx_runtime from 'react/jsx-runtime';
2
+ import { I_ApolloOptions, T_Children } from '../../typescript/react.js';
3
+ import '@apollo/client';
4
+ import 'react';
5
+
6
+ declare function ApolloProvider({ options, children }: {
7
+ options: I_ApolloOptions;
8
+ children: T_Children;
9
+ }): react_jsx_runtime.JSX.Element;
10
+
11
+ export { ApolloProvider };
@@ -0,0 +1,6 @@
1
+ export { ApolloProvider } from './apollo-client.cjs';
2
+ export { LoadingProvider } from './loading.cjs';
3
+ import 'react/jsx-runtime';
4
+ import '../../typescript/react.cjs';
5
+ import '@apollo/client';
6
+ import 'react';
@@ -0,0 +1,6 @@
1
+ export { ApolloProvider } from './apollo-client.js';
2
+ export { LoadingProvider } from './loading.js';
3
+ import 'react/jsx-runtime';
4
+ import '../../typescript/react.js';
5
+ import '@apollo/client';
6
+ import 'react';
@@ -0,0 +1,10 @@
1
+ import * as react_jsx_runtime from 'react/jsx-runtime';
2
+ import { T_Children } from '../../typescript/react.cjs';
3
+ import '@apollo/client';
4
+ import 'react';
5
+
6
+ declare function LoadingProvider({ children }: {
7
+ children: T_Children;
8
+ }): react_jsx_runtime.JSX.Element;
9
+
10
+ export { LoadingProvider };
@@ -0,0 +1,10 @@
1
+ import * as react_jsx_runtime from 'react/jsx-runtime';
2
+ import { T_Children } from '../../typescript/react.js';
3
+ import '@apollo/client';
4
+ import 'react';
5
+
6
+ declare function LoadingProvider({ children }: {
7
+ children: T_Children;
8
+ }): react_jsx_runtime.JSX.Element;
9
+
10
+ export { LoadingProvider };
@@ -1 +1 @@
1
- "use strict";function e(e){"@swc/helpers - typeof";return e&&typeof Symbol!=="undefined"&&e.constructor===Symbol?"symbol":typeof e}var n=Object.defineProperty;var t=Object.getOwnPropertyDescriptor;var r=Object.getOwnPropertyNames;var i=Object.prototype.hasOwnProperty;var u=function(e,t){for(var r in t)n(e,r,{get:t[r],enumerable:!0})},o=function(u,o,s,a){var c=true,f=false,l=undefined;if(o&&(typeof o==="undefined"?"undefined":e(o))=="object"||typeof o=="function")try{var p=function(){var e=d.value;!i.call(u,e)&&e!==s&&n(u,e,{get:function(){return o[e]},enumerable:!(a=t(o,e))||a.enumerable})};for(var y=r(o)[Symbol.iterator](),d;!(c=(d=y.next()).done);c=true)p()}catch(e){f=true;l=e}finally{try{if(!c&&y.return!=null){y.return()}}finally{if(f){throw l}}}return u};var s=function(e){return o(n({},"__esModule",{value:!0}),e)};var a={};u(a,{E_ErrorType:function(){return f},E_SpinnerMessage:function(){return c}});module.exports=s(a);var c=function(e){return e.LintCheck="Running lint checks...",e.LintFix="Fixing issues...",e.LintStaged="Running lint-staged...",e.CommitLint="Running commitlint...",e.Setup="Setting up...",e.Reset="Resetting...",e.UnitTest="Running unit tests...",e.E2ETest="Running end-to-end tests...",e.Success=" completed successfully!",e.Fail=" failed.",e}(c||{}),f=function(e){return e.Error="error",e.Warning="warning",e}(f||{});0&&(module.exports={E_ErrorType:E_ErrorType,E_SpinnerMessage:E_SpinnerMessage});
1
+ "use strict";function e(e){"@swc/helpers - typeof";return e&&typeof Symbol!=="undefined"&&e.constructor===Symbol?"symbol":typeof e}var n=Object.defineProperty;var t=Object.getOwnPropertyDescriptor;var r=Object.getOwnPropertyNames;var i=Object.prototype.hasOwnProperty;var o=function(e,t){for(var r in t)n(e,r,{get:t[r],enumerable:!0})},u=function(o,u,a,s){var f=true,c=false,l=undefined;if(u&&(typeof u==="undefined"?"undefined":e(u))=="object"||typeof u=="function")try{var p=function(){var e=g.value;!i.call(o,e)&&e!==a&&n(o,e,{get:function(){return u[e]},enumerable:!(s=t(u,e))||s.enumerable})};for(var y=r(u)[Symbol.iterator](),g;!(f=(g=y.next()).done);f=true)p()}catch(e){c=true;l=e}finally{try{if(!f&&y.return!=null){y.return()}}finally{if(c){throw l}}}return o};var a=function(e){return u(n({},"__esModule",{value:!0}),e)};var s={};o(s,{E_ErrorType:function(){return c},E_SpinnerMessage:function(){return f}});module.exports=a(s);var f=function(e){return e.LintCheck="Running lint checks...",e.LintFix="Fixing issues...",e.LintStaged="Running lint-staged...",e.CommitLint="Running commitlint...",e.Setup="Setting up...",e.Reset="Resetting...",e.UnitTest="Running unit tests...",e.E2ETest="Running end-to-end tests...",e}(f||{}),c=function(e){return e.Error="error",e.Warning="warning",e}(c||{});0&&(module.exports={E_ErrorType:E_ErrorType,E_SpinnerMessage:E_SpinnerMessage});
@@ -0,0 +1,39 @@
1
+ declare enum E_SpinnerMessage {
2
+ LintCheck = "Running lint checks...",
3
+ LintFix = "Fixing issues...",
4
+ LintStaged = "Running lint-staged...",
5
+ CommitLint = "Running commitlint...",
6
+ Setup = "Setting up...",
7
+ Reset = "Resetting...",
8
+ UnitTest = "Running unit tests...",
9
+ E2ETest = "Running end-to-end tests..."
10
+ }
11
+ declare enum E_ErrorType {
12
+ Error = "error",
13
+ Warning = "warning"
14
+ }
15
+ interface I_ErrorEntry {
16
+ type: E_ErrorType;
17
+ file: string;
18
+ message: string;
19
+ position?: string;
20
+ rule?: string;
21
+ }
22
+ interface I_EslintError {
23
+ filePath: string;
24
+ messages: Array<{
25
+ line: number;
26
+ column: number;
27
+ severity: number;
28
+ message: string;
29
+ ruleId: string;
30
+ }>;
31
+ }
32
+ interface I_SpinnerOptions {
33
+ successMessage?: string;
34
+ failureMessage?: string;
35
+ errorList?: unknown[];
36
+ exitOnError?: boolean;
37
+ }
38
+
39
+ export { E_ErrorType, E_SpinnerMessage, type I_ErrorEntry, type I_EslintError, type I_SpinnerOptions };
@@ -0,0 +1,39 @@
1
+ declare enum E_SpinnerMessage {
2
+ LintCheck = "Running lint checks...",
3
+ LintFix = "Fixing issues...",
4
+ LintStaged = "Running lint-staged...",
5
+ CommitLint = "Running commitlint...",
6
+ Setup = "Setting up...",
7
+ Reset = "Resetting...",
8
+ UnitTest = "Running unit tests...",
9
+ E2ETest = "Running end-to-end tests..."
10
+ }
11
+ declare enum E_ErrorType {
12
+ Error = "error",
13
+ Warning = "warning"
14
+ }
15
+ interface I_ErrorEntry {
16
+ type: E_ErrorType;
17
+ file: string;
18
+ message: string;
19
+ position?: string;
20
+ rule?: string;
21
+ }
22
+ interface I_EslintError {
23
+ filePath: string;
24
+ messages: Array<{
25
+ line: number;
26
+ column: number;
27
+ severity: number;
28
+ message: string;
29
+ ruleId: string;
30
+ }>;
31
+ }
32
+ interface I_SpinnerOptions {
33
+ successMessage?: string;
34
+ failureMessage?: string;
35
+ errorList?: unknown[];
36
+ exitOnError?: boolean;
37
+ }
38
+
39
+ export { E_ErrorType, E_SpinnerMessage, type I_ErrorEntry, type I_EslintError, type I_SpinnerOptions };
@@ -1 +1 @@
1
- var n=function(n){return n.LintCheck="Running lint checks...",n.LintFix="Fixing issues...",n.LintStaged="Running lint-staged...",n.CommitLint="Running commitlint...",n.Setup="Setting up...",n.Reset="Resetting...",n.UnitTest="Running unit tests...",n.E2ETest="Running end-to-end tests...",n.Success=" completed successfully!",n.Fail=" failed.",n}(n||{}),t=function(n){return n.Error="error",n.Warning="warning",n}(t||{});export{t as E_ErrorType,n as E_SpinnerMessage};
1
+ var n=function(n){return n.LintCheck="Running lint checks...",n.LintFix="Fixing issues...",n.LintStaged="Running lint-staged...",n.CommitLint="Running commitlint...",n.Setup="Setting up...",n.Reset="Resetting...",n.UnitTest="Running unit tests...",n.E2ETest="Running end-to-end tests...",n}(n||{}),t=function(n){return n.Error="error",n.Warning="warning",n}(t||{});export{t as E_ErrorType,n as E_SpinnerMessage};
@@ -0,0 +1,5 @@
1
+ interface I_Config {
2
+ [key: string]: string | number | boolean | I_Config | I_Config[];
3
+ }
4
+
5
+ export type { I_Config };
@@ -0,0 +1,5 @@
1
+ interface I_Config {
2
+ [key: string]: string | number | boolean | I_Config | I_Config[];
3
+ }
4
+
5
+ export type { I_Config };