lancer-shared 1.0.175 → 1.2.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 (54) hide show
  1. package/dist/bundle.cjs.js +6404 -265
  2. package/dist/constants/collections.d.ts +1 -0
  3. package/dist/constants/collections.js +10 -9
  4. package/dist/constants/index.d.ts +9 -8
  5. package/dist/constants/organization.d.ts +2 -0
  6. package/dist/constants/routes.d.ts +54 -0
  7. package/dist/index.d.ts +4 -4
  8. package/dist/schemas/account/bidder-account.d.ts +8 -1
  9. package/dist/schemas/account/bidder-account.js +5 -4
  10. package/dist/schemas/bid/bid-result.d.ts +0 -3
  11. package/dist/schemas/bid/bid-result.js +0 -1
  12. package/dist/schemas/bid/bid.d.ts +13 -31
  13. package/dist/schemas/bid/bid.js +7 -5
  14. package/dist/schemas/campaign/campaign-analytics.d.ts +328 -0
  15. package/dist/schemas/campaign/campaign-analytics.js +4 -0
  16. package/dist/schemas/index.d.ts +2 -1
  17. package/dist/schemas/index.js +2 -1
  18. package/dist/schemas/lead/index.d.ts +16 -6
  19. package/dist/schemas/lead/index.js +8 -1
  20. package/dist/schemas/lead/nuxt.js +287 -0
  21. package/dist/schemas/logger/log-event.d.ts +45 -5
  22. package/dist/schemas/logger/log-event.js +73 -41
  23. package/dist/schemas/organization/index.d.ts +341 -1
  24. package/dist/schemas/organization/index.js +70 -1
  25. package/dist/schemas/organization/member.d.ts +18 -0
  26. package/dist/schemas/organization/member.js +7 -0
  27. package/dist/schemas/organization/organization.d.ts +177 -7
  28. package/dist/schemas/organization/subscription.d.ts +28 -0
  29. package/dist/schemas/organization/subscription.js +17 -0
  30. package/dist/schemas/proxy/index.js +2 -0
  31. package/dist/schemas/proxy/proxy-available-replacements.js +3 -0
  32. package/dist/schemas/proxy/proxy-country.js +249 -0
  33. package/dist/schemas/proxy/proxy.d.ts +5 -5
  34. package/dist/schemas/proxy/proxy.js +13 -2
  35. package/dist/schemas/transaction/index.d.ts +31 -0
  36. package/dist/schemas/transaction/index.js +17 -0
  37. package/dist/schemas/usage/index.d.ts +72 -0
  38. package/dist/schemas/usage/index.js +18 -0
  39. package/dist/types/campaign/campaign-analytics.d.ts +3 -1
  40. package/dist/types/index.d.ts +2 -1
  41. package/dist/types/index.js +2 -1
  42. package/dist/types/job/index.d.ts +3 -2
  43. package/dist/types/job/index.js +1 -0
  44. package/dist/types/job/nuxt.js +1 -0
  45. package/dist/types/logger/log-event.d.ts +6 -2
  46. package/dist/types/shared.d.ts +5 -0
  47. package/dist/types/transaction/index.d.ts +4 -0
  48. package/dist/types/transaction/index.js +1 -0
  49. package/dist/types/usage/index.d.ts +6 -0
  50. package/dist/types/usage/index.js +1 -0
  51. package/dist/types/user/index.d.ts +2 -1
  52. package/dist/utils/index.d.ts +2 -1
  53. package/dist/utils/shared.d.ts +3 -0
  54. package/package.json +9 -3
@@ -1,10 +1,11 @@
1
1
  import { z } from "zod";
2
- import { loginSchema, registerSchema, upworkProfileSchema, userSchema } from "../../schemas";
2
+ import { loginSchema, Organization, registerSchema, upworkProfileSchema, userSchema } from "../../schemas";
3
3
  import { Lead } from "../job";
4
4
  import { SavedSearch } from "../saved-search";
5
5
  export interface User extends z.infer<typeof userSchema> {
6
6
  jobs?: Lead[];
7
7
  savedSearches?: SavedSearch[];
8
+ organizations?: Organization[];
8
9
  }
9
10
  export interface RegisterSchema extends z.infer<typeof registerSchema> {
10
11
  }
@@ -1 +1,2 @@
1
- export * from './try-catch';
1
+ export * from "./try-catch";
2
+ export * from "./shared";
@@ -0,0 +1,3 @@
1
+ export declare const isNumeric: (num: any) => boolean;
2
+ export declare const formatCurrency: (price: string | number | null | undefined, currencyCode?: string | null | undefined) => string;
3
+ export declare const capitalize: (str: string) => string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lancer-shared",
3
- "version": "1.0.175",
3
+ "version": "1.2.0",
4
4
  "description": "This package contains shared stuff.",
5
5
  "types": "./dist/index.d.ts",
6
6
  "main": "dist/bundle.cjs.js",
@@ -13,6 +13,9 @@
13
13
  "dist/constants/**",
14
14
  "dist/utils/**"
15
15
  ],
16
+ "engines": {
17
+ "node": "22"
18
+ },
16
19
  "scripts": {
17
20
  "test": "echo \"Error: no test specified\" && exit 1",
18
21
  "prepublishOnly": "npm run build",
@@ -23,18 +26,21 @@
23
26
  "author": "MVP Masters",
24
27
  "license": "ISC",
25
28
  "dependencies": {
29
+ "currency-symbol-map": "^5.1.0",
26
30
  "lodash": "4.17.21",
31
+ "moment": "^2.30.1",
27
32
  "slugify": "1.6.6",
28
33
  "zod": "3.24.2"
29
34
  },
30
35
  "devDependencies": {
36
+ "@rollup/plugin-commonjs": "^28.0.3",
37
+ "@rollup/plugin-node-resolve": "^16.0.1",
31
38
  "@types/lodash": "4.17.1",
32
39
  "@types/multer": "1.4.12",
33
40
  "@types/node": "22.5.2",
34
41
  "rollup": "4.38.0",
35
42
  "rollup-plugin-typescript2": "0.36.0",
36
43
  "rollup-watch": "4.3.1",
37
- "@rollup/plugin-node-resolve": "^16.0.1",
38
44
  "typescript": "5.4.5"
39
45
  }
40
- }
46
+ }