@putkoff/abstract-utilities 0.0.7 → 0.1.1

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 (35) hide show
  1. package/dist/cjs/functions/fetch_utils/imports.d.ts +1 -0
  2. package/dist/cjs/functions/fetch_utils/index.d.ts +1 -1
  3. package/dist/cjs/functions/fetch_utils/src/getAppConfig.d.ts +1 -0
  4. package/dist/cjs/functions/fetch_utils/src/index.d.ts +1 -1
  5. package/dist/cjs/index.d.ts +0 -1
  6. package/dist/cjs/index.js +14 -23
  7. package/dist/cjs/index.js.map +1 -1
  8. package/dist/cjs/utils/imports.d.ts +1 -0
  9. package/dist/cjs/utils/index.d.ts +1 -0
  10. package/dist/cjs/utils/src/Input.d.ts +13 -0
  11. package/dist/cjs/utils/src/config.d.ts +5 -0
  12. package/dist/cjs/utils/src/index.d.ts +2 -0
  13. package/dist/esm/functions/fetch_utils/imports.d.ts +1 -0
  14. package/dist/esm/functions/fetch_utils/index.d.ts +1 -1
  15. package/dist/esm/functions/fetch_utils/src/getAppConfig.d.ts +1 -0
  16. package/dist/esm/functions/fetch_utils/src/index.d.ts +1 -1
  17. package/dist/esm/index.d.ts +0 -1
  18. package/dist/esm/index.js +15 -23
  19. package/dist/esm/index.js.map +1 -1
  20. package/dist/esm/utils/imports.d.ts +1 -0
  21. package/dist/esm/utils/index.d.ts +1 -0
  22. package/dist/esm/utils/src/Input.d.ts +13 -0
  23. package/dist/esm/utils/src/config.d.ts +5 -0
  24. package/dist/esm/utils/src/index.d.ts +2 -0
  25. package/dist/functions/fetch_utils/imports.d.ts +1 -0
  26. package/dist/functions/fetch_utils/index.d.ts +1 -1
  27. package/dist/functions/fetch_utils/src/getAppConfig.d.ts +1 -0
  28. package/dist/functions/fetch_utils/src/index.d.ts +1 -1
  29. package/dist/index.d.ts +1 -7
  30. package/dist/utils/imports.d.ts +1 -0
  31. package/dist/utils/index.d.ts +1 -0
  32. package/dist/utils/src/Input.d.ts +13 -0
  33. package/dist/utils/src/config.d.ts +5 -0
  34. package/dist/utils/src/index.d.ts +2 -0
  35. package/package.json +1 -1
@@ -0,0 +1 @@
1
+ export type { InputProps } from "./../types";
@@ -0,0 +1 @@
1
+ export * from './src';
@@ -0,0 +1,13 @@
1
+ /**
2
+
3
+ ***Changes**:
4
+ *- Updated import paths to match the library structure (`../utils`, `../functions/fetch`, `../functions/auth`).
5
+ *- Added `getAuthorizationHeader` import to support token-based authentication.
6
+ *- Adjusted the `secureFetchIt` call to expect a response with `{ result: { token: string }; success: boolean }`, matching the `api.ts` expectation.
7
+ *
8
+ *2. **Input Component** (`src/utils/Input.tsx`):
9
+ * Copy from `/var/www/abstractendeavors/my-login-app/src/components/utils/src/Inputs.tsx`.
10
+ *
11
+ */
12
+ import type { InputProps } from "./../imports";
13
+ export declare const Input: React.FC<InputProps>;
@@ -0,0 +1,5 @@
1
+ export interface AppConfig {
2
+ API_BASE_URL: string;
3
+ }
4
+ export declare let AppConfig: AppConfig;
5
+ export declare function loadConfig(): Promise<void>;
@@ -0,0 +1,2 @@
1
+ export * from "./Input";
2
+ export { loadConfig } from './config';
@@ -4,4 +4,5 @@ export { stripPrefixes } from './../string_utils';
4
4
  export { alertit } from './../rndm_utils';
5
5
  export { ensure_list } from './../type_utils';
6
6
  export { eatInner } from './../string_utils';
7
+ export { AppConfig } from './../../utils/src/config';
7
8
  export type { LogoutButtonProps, FetchVariables } from './../../types';
@@ -1 +1 @@
1
- export * from './fetchIt_utils';
1
+ export * from './src';
@@ -0,0 +1 @@
1
+ export declare function getAppConfig(endpoint: string): string;
@@ -1 +1 @@
1
- export * from './utils';
1
+ export * from './fetchIt_utils';
package/dist/index.d.ts CHANGED
@@ -2,12 +2,6 @@ import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
  import * as react from 'react';
3
3
  import react__default from 'react';
4
4
 
5
- interface AppConfig {
6
- API_BASE_URL: string;
7
- }
8
- declare let AppConfig: AppConfig;
9
- declare function loadConfig(): Promise<void>;
10
-
11
5
  /** Non-React “direct download” used by some old links (kept for parity) */
12
6
  declare function directDownload(relPath: string, filename: string): Promise<void>;
13
7
 
@@ -359,4 +353,4 @@ declare function useFiles(): {
359
353
  */
360
354
  declare const useDeleteFile: (setFiles: React.Dispatch<React.SetStateAction<FileItem[]>>) => (file: FileItem) => Promise<void>;
361
355
 
362
- export { API_PREFIX, type ApiRow, AppConfig, BASE_URL, Button, type ChangePasswordFormProps, type ChangePasswordProps, Checkbox, DEV_PREFIX, DOMAIN_NAME, type FetchVariables, type FileItem, type FileListResponse, Input, type InputProps, type JwtPayload, type LoginFormProps, type LoginProps, type LogoutButtonProps, PROD_PREFIX, PROTOCOL, SUB_DIR, Spinner, alertit, currentUsername, currentUsernames, decodeJwt, directDownload, downloadFile, downloadRow, downloadSelect, downloadSelected, eatAll, eatEnd, eatInner, eatOuter, ensure_list, fetchIt, fetchSharePatch, geAuthsUtilsDirectory, geBackupsUtilsDirectory, geConstantsUtilsDirectory, geEnvUtilsDirectory, geFetchUtilsDirectory, geFileUtilsDirectory, gePathUtilsDirectory, geStaticDirectory, geStringUtilsDirectory, geTypeUtilsDirectory, getAbsDir, getAbsPath, getAuthorizationHeader, getBaseDir, getComponentsUtilsDirectory, getDbConfigsPath, getDistDir, getEnvDir, getEnvPath, getFunctionsDir, getFunctionsUtilsDirectory, getHooksUtilsDirectory, getLibUtilsDirectory, getPublicDir, getSchemasDirPath, getSchemasPath, getSrcDir, getSubstring, getToggleShare, getToken, get_basename, get_dirname, get_extname, get_filename, get_splitext, get_window, get_window_location, get_window_parts, get_window_pathname, initSelectAll, isLoggedIn, isTokenExpired, listFiles, loadConfig, make_path, make_sanitized_path, normalizeUrl, patchFileSetting, removeFile, removeRow, removeSelected, requestPatch, requireToken, sanitizeFilename, secureFetchIt, stripPrefixes, syncHeaderCheckbox, toggleCheckboxes, toggleShare, triggerDownload, truncateString, updateFileShare, uploadFile, uploadFiles, useDeleteFile, useFiles, useLoadFiles, usePatchShareSettings, useToggleShare };
356
+ export { API_PREFIX, type ApiRow, BASE_URL, Button, type ChangePasswordFormProps, type ChangePasswordProps, Checkbox, DEV_PREFIX, DOMAIN_NAME, type FetchVariables, type FileItem, type FileListResponse, Input, type InputProps, type JwtPayload, type LoginFormProps, type LoginProps, type LogoutButtonProps, PROD_PREFIX, PROTOCOL, SUB_DIR, Spinner, alertit, currentUsername, currentUsernames, decodeJwt, directDownload, downloadFile, downloadRow, downloadSelect, downloadSelected, eatAll, eatEnd, eatInner, eatOuter, ensure_list, fetchIt, fetchSharePatch, geAuthsUtilsDirectory, geBackupsUtilsDirectory, geConstantsUtilsDirectory, geEnvUtilsDirectory, geFetchUtilsDirectory, geFileUtilsDirectory, gePathUtilsDirectory, geStaticDirectory, geStringUtilsDirectory, geTypeUtilsDirectory, getAbsDir, getAbsPath, getAuthorizationHeader, getBaseDir, getComponentsUtilsDirectory, getDbConfigsPath, getDistDir, getEnvDir, getEnvPath, getFunctionsDir, getFunctionsUtilsDirectory, getHooksUtilsDirectory, getLibUtilsDirectory, getPublicDir, getSchemasDirPath, getSchemasPath, getSrcDir, getSubstring, getToggleShare, getToken, get_basename, get_dirname, get_extname, get_filename, get_splitext, get_window, get_window_location, get_window_parts, get_window_pathname, initSelectAll, isLoggedIn, isTokenExpired, listFiles, make_path, make_sanitized_path, normalizeUrl, patchFileSetting, removeFile, removeRow, removeSelected, requestPatch, requireToken, sanitizeFilename, secureFetchIt, stripPrefixes, syncHeaderCheckbox, toggleCheckboxes, toggleShare, triggerDownload, truncateString, updateFileShare, uploadFile, uploadFiles, useDeleteFile, useFiles, useLoadFiles, usePatchShareSettings, useToggleShare };
@@ -0,0 +1 @@
1
+ export type { InputProps } from "./../types";
@@ -0,0 +1 @@
1
+ export * from './src';
@@ -0,0 +1,13 @@
1
+ /**
2
+
3
+ ***Changes**:
4
+ *- Updated import paths to match the library structure (`../utils`, `../functions/fetch`, `../functions/auth`).
5
+ *- Added `getAuthorizationHeader` import to support token-based authentication.
6
+ *- Adjusted the `secureFetchIt` call to expect a response with `{ result: { token: string }; success: boolean }`, matching the `api.ts` expectation.
7
+ *
8
+ *2. **Input Component** (`src/utils/Input.tsx`):
9
+ * Copy from `/var/www/abstractendeavors/my-login-app/src/components/utils/src/Inputs.tsx`.
10
+ *
11
+ */
12
+ import type { InputProps } from "./../imports";
13
+ export declare const Input: React.FC<InputProps>;
@@ -0,0 +1,5 @@
1
+ export interface AppConfig {
2
+ API_BASE_URL: string;
3
+ }
4
+ export declare let AppConfig: AppConfig;
5
+ export declare function loadConfig(): Promise<void>;
@@ -0,0 +1,2 @@
1
+ export * from "./Input";
2
+ export { loadConfig } from './config';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@putkoff/abstract-utilities",
3
- "version": "0.0.7",
3
+ "version": "0.1.1",
4
4
  "type": "module",
5
5
  "description": "A reusable React Login component with JWT authentication",
6
6
  "main": "dist/cjs/index.js",