@vonq/hapi-elements-types 1.22.0 → 1.24.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 (100) hide show
  1. package/_window/api.types.ts +12 -13
  2. package/_window/index.ts.bak +16 -0
  3. package/_window/qa.types.ts +1 -0
  4. package/_window/sdk.types.ts +5 -2
  5. package/_window/service.types.ts +3 -12
  6. package/_window/state.types.ts +0 -24
  7. package/_window/ui.types.ts +8 -1
  8. package/_window/utils.types.ts +3 -0
  9. package/_window/window.ts +22 -3
  10. package/alert/index.ts +4 -4
  11. package/alert/index.ts.bak +6 -0
  12. package/ats/index.ts +4 -4
  13. package/ats/index.ts.bak +6 -0
  14. package/ats/types.ts +7 -1
  15. package/basket/index.ts +5 -5
  16. package/basket/index.ts.bak +7 -0
  17. package/basket/service.types.ts +3 -1
  18. package/basket/utils.types.ts +6 -2
  19. package/campaign/api.types.ts +5 -1
  20. package/campaign/enums.ts +0 -3
  21. package/campaign/index.ts +8 -8
  22. package/campaign/index.ts.bak +10 -0
  23. package/campaign/service.types.ts +14 -0
  24. package/campaign/types.ts +31 -21
  25. package/campaign/utils.types.ts +1 -0
  26. package/campaign/validations.types.ts +15 -1
  27. package/common/enums.ts +0 -4
  28. package/common/events/EventCommand/index.ts.bak +4 -0
  29. package/common/events/index.ts.bak +4 -0
  30. package/common/index.ts +7 -5
  31. package/common/index.ts.bak +9 -0
  32. package/common/logger/index.ts +4 -0
  33. package/common/logger/index.ts.bak +4 -0
  34. package/common/types.ts +20 -3
  35. package/common/validations.types.ts +2 -0
  36. package/common/validator/index.ts +3 -0
  37. package/common/validator/index.ts.bak +3 -0
  38. package/contract/api.types.ts +1 -0
  39. package/contract/index.ts +7 -7
  40. package/contract/index.ts.bak +9 -0
  41. package/contract/service.types.ts +7 -1
  42. package/contract/types.ts +2 -0
  43. package/contract/validations.types.ts +1 -0
  44. package/debugging/index.ts +3 -2
  45. package/debugging/index.ts.bak +5 -0
  46. package/index.ts +16 -16
  47. package/index.ts.bak +18 -0
  48. package/language/enums.ts +5 -0
  49. package/language/index.ts +6 -3
  50. package/language/index.ts.bak +8 -0
  51. package/language/service.types.ts +7 -0
  52. package/language/state.types.ts +3 -1
  53. package/language/utils.types.ts +11 -0
  54. package/modal/enums.ts +3 -3
  55. package/modal/index.ts +5 -4
  56. package/modal/index.ts.bak +7 -0
  57. package/modal/types.ts +11 -8
  58. package/orderJourney/index.ts +7 -6
  59. package/orderJourney/index.ts.bak +9 -0
  60. package/orderJourney/qa.types.ts +3 -1
  61. package/orderJourney/service.types.ts +3 -8
  62. package/orderJourney/state.types.ts +31 -8
  63. package/orderJourney/types.ts +79 -16
  64. package/orderJourney/validations.types.ts +13 -2
  65. package/package.json +2 -3
  66. package/product/index.ts +8 -8
  67. package/product/index.ts.bak +10 -0
  68. package/product/types.ts +4 -1
  69. package/routing/index.ts +2 -1
  70. package/routing/index.ts.bak +4 -0
  71. package/theming/index.ts +4 -4
  72. package/theming/index.ts.bak +6 -0
  73. package/theming/types.ts +44 -0
  74. package/theming/validations.types.ts +16 -0
  75. package/ui/index.ts.bak +3 -0
  76. package/wallet/index.ts +5 -5
  77. package/wallet/index.ts.bak +7 -0
  78. package/wallet/state.types.ts +1 -1
  79. package/wallet/types.ts +6 -1
  80. package/talentMindCompany/api.types.ts +0 -18
  81. package/talentMindCompany/service.types.ts +0 -15
  82. package/talentMindCompany/state.types.ts +0 -5
  83. package/talentMindCompany/types.ts +0 -6
  84. package/talentMindCompany/validations.types.ts +0 -5
  85. package/talentMindEvaluation/api.types.ts +0 -25
  86. package/talentMindEvaluation/service.types.ts +0 -25
  87. package/talentMindEvaluation/state.types.ts +0 -6
  88. package/talentMindEvaluation/types.ts +0 -15
  89. package/talentMindEvaluation/validations.types.ts +0 -5
  90. package/talentMindJob/api.types.ts +0 -26
  91. package/talentMindJob/service.types.ts +0 -28
  92. package/talentMindJob/state.types.ts +0 -6
  93. package/talentMindJob/types.ts +0 -12
  94. package/talentMindJob/validations.types.ts +0 -5
  95. package/talentMindResume/api.types.ts +0 -30
  96. package/talentMindResume/service.types.ts +0 -34
  97. package/talentMindResume/state.types.ts +0 -6
  98. package/talentMindResume/types.ts +0 -119
  99. package/talentMindResume/validations.types.ts +0 -5
  100. package/tsconfig.json +0 -36
@@ -1,20 +1,32 @@
1
1
  import { OrderJourneyPaymentMethod, OrderJourneyStepKey } from "./enums"
2
2
  import {
3
- OrderJourneyStep,
4
3
  OrderJourneyContractStep,
5
- OrderJourneyUTMStepData,
6
- OrderJourneyUTMStepValidations,
4
+ OrderJourneyOrderConfirmationStepData,
5
+ OrderJourneyOrderErrors,
6
+ OrderJourneyOrderErrorsCampaignIsInvalidWithOrderedProducts,
7
+ OrderJourneyOrderErrorsCampaignIsInvalidWithOrderedProductsSpecs,
8
+ OrderJourneyOrderErrorsCampaignIsInvalidWithPaymentMethod,
9
+ OrderJourneyOrderErrorsCampaignIsInvalidWithRecruiterInfo,
10
+ OrderJourneyOrderErrorsCampaignIsInvalidWithTargetGroup,
11
+ OrderJourneyOrderErrorsCampaignIsInvalidWithWalletId,
12
+ OrderJourneyOrderErrorsPostingDetailsBase,
13
+ OrderJourneyOrderErrorsPostingDetailsOrganization,
14
+ OrderJourneyOrderErrorsPostingDetailsURLs,
15
+ OrderJourneyOrderErrorsPostingDetailsWorkingLocation,
7
16
  OrderJourneyOrderReviewStepData,
8
17
  OrderJourneyProductStep,
9
- OrderJourneyOrderErrors,
10
- OrderJourneyOrderConfirmationStepData,
18
+ OrderJourneyStep,
19
+ OrderJourneyUTMStepData,
20
+ OrderJourneyUTMStepValidations,
11
21
  } from "./types"
12
22
  import { MessageDescriptor } from "react-intl"
13
23
  import { NestedValidatorKeys, UseValidatorResult } from "../common/types"
14
24
 
15
25
  export type OrderJourneyState = {
16
- stepsEnabled: OrderJourneyStepKey[]
17
- steps: OrderJourneyStep[]
26
+ stepsEnabled: (OrderJourneyStepKey | OrderJourneyStepKey[])[]
27
+ steps: (OrderJourneyStep | OrderJourneyStep[])[]
28
+ stepsAreGroups: boolean
29
+ flattenedSteps: OrderJourneyStep[]
18
30
  stepPreviousIndex: number
19
31
  stepActiveIndex: number
20
32
  stepNextIndex: number
@@ -29,7 +41,18 @@ export type OrderJourneyState = {
29
41
  paymentMethodsEnabled: OrderJourneyPaymentMethod[]
30
42
  hidePrefilledFields: boolean
31
43
  orderErrors: OrderJourneyOrderErrors | null
32
- stepActiveOrderErrors: OrderJourneyOrderErrors | null
44
+ stepActiveOrderErrors:
45
+ | OrderJourneyOrderErrorsPostingDetailsOrganization
46
+ | OrderJourneyOrderErrorsPostingDetailsWorkingLocation
47
+ | OrderJourneyOrderErrorsPostingDetailsURLs
48
+ | OrderJourneyOrderErrorsPostingDetailsBase
49
+ | OrderJourneyOrderErrorsCampaignIsInvalidWithRecruiterInfo
50
+ | OrderJourneyOrderErrorsCampaignIsInvalidWithTargetGroup
51
+ | OrderJourneyOrderErrorsCampaignIsInvalidWithOrderedProducts
52
+ | OrderJourneyOrderErrorsCampaignIsInvalidWithOrderedProductsSpecs
53
+ | OrderJourneyOrderErrorsCampaignIsInvalidWithWalletId
54
+ | OrderJourneyOrderErrorsCampaignIsInvalidWithPaymentMethod
55
+ | null
33
56
  /* Onboarding */
34
57
  onboardingStep: OrderJourneyStep
35
58
  onboardingStepData: Record<string, any>
@@ -61,8 +61,7 @@ export type OrderJourneyUTMStepValidations = {
61
61
  }
62
62
  }
63
63
  >
64
- areAllValid: boolean
65
- }
64
+ } & UseValidatorResult
66
65
 
67
66
  export type OrderJourneyOrderReviewStepData = {
68
67
  accordionsOpen: OrderJourneyStepKey[]
@@ -94,14 +93,32 @@ export type OrderJourneyOrderErrorsRecruiterInfo = {
94
93
 
95
94
  export type OrderJourneyOrderErrorsTargetGroup = string[]
96
95
 
97
- export type OrderJourneyOrderErrorsPostingDetails = {
98
- title?: string[]
99
- description?: string[]
100
- employmentType?: string[]
96
+ export type OrderJourneyOrderErrorsPostingDetailsOrganization = {
101
97
  organization?: {
102
98
  name?: string[]
103
99
  companyLogo?: string[]
104
100
  }
101
+ }
102
+
103
+ export type OrderJourneyOrderErrorsPostingDetailsWorkingLocation = {
104
+ workingLocation?: {
105
+ addressLine1?: string[]
106
+ addressLine2?: string[]
107
+ city?: string[]
108
+ country?: string[]
109
+ postcode?: string[]
110
+ }
111
+ }
112
+
113
+ export type OrderJourneyOrderErrorsPostingDetailsURLs = {
114
+ jobPageUrl?: string[]
115
+ applicationUrl?: string[]
116
+ }
117
+
118
+ export type OrderJourneyOrderErrorsPostingDetailsBase = {
119
+ title?: string[]
120
+ description?: string[]
121
+ employmentType?: string[]
105
122
  salaryIndication?: {
106
123
  period?: string[]
107
124
  to?: string[]
@@ -112,26 +129,51 @@ export type OrderJourneyOrderErrorsPostingDetails = {
112
129
  from?: string[]
113
130
  to?: string[]
114
131
  }
115
- workingLocation?: {
116
- addressLine1?: string[]
117
- addressLine2?: string[]
118
- city?: string[]
119
- country?: string[]
120
- postcode?: string[]
121
- }
122
- jobPageUrl?: string[]
123
- applicationUrl?: string[]
124
132
  }
125
133
 
126
- export type OrderJourneyOrderErrorsCampaignIsInvalid = {
134
+ export type OrderJourneyOrderErrorsPostingDetails =
135
+ OrderJourneyOrderErrorsPostingDetailsOrganization &
136
+ OrderJourneyOrderErrorsPostingDetailsWorkingLocation &
137
+ OrderJourneyOrderErrorsPostingDetailsURLs &
138
+ OrderJourneyOrderErrorsPostingDetailsBase
139
+
140
+ export type OrderJourneyOrderErrorsCampaignIsInvalidWithPostingDetails = {
127
141
  postingDetails?: OrderJourneyOrderErrorsPostingDetails
142
+ }
143
+
144
+ export type OrderJourneyOrderErrorsCampaignIsInvalidWithRecruiterInfo = {
128
145
  recruiterInfo?: OrderJourneyOrderErrorsRecruiterInfo
146
+ }
147
+
148
+ export type OrderJourneyOrderErrorsCampaignIsInvalidWithTargetGroup = {
129
149
  targetGroup?: OrderJourneyOrderErrorsTargetGroup
150
+ }
151
+
152
+ export type OrderJourneyOrderErrorsCampaignIsInvalidWithOrderedProducts = {
130
153
  orderedProducts?: string[]
154
+ }
155
+
156
+ export type OrderJourneyOrderErrorsCampaignIsInvalidWithPaymentMethod = {
157
+ paymentMethod?: string[]
158
+ }
159
+
160
+ export type OrderJourneyOrderErrorsCampaignIsInvalidWithOrderedProductsSpecs = {
131
161
  orderedProductsSpecs?: any[]
162
+ }
163
+
164
+ export type OrderJourneyOrderErrorsCampaignIsInvalidWithWalletId = {
132
165
  walletId?: string
133
166
  }
134
167
 
168
+ export type OrderJourneyOrderErrorsCampaignIsInvalid =
169
+ OrderJourneyOrderErrorsCampaignIsInvalidWithPostingDetails &
170
+ OrderJourneyOrderErrorsCampaignIsInvalidWithRecruiterInfo &
171
+ OrderJourneyOrderErrorsCampaignIsInvalidWithTargetGroup &
172
+ OrderJourneyOrderErrorsCampaignIsInvalidWithOrderedProducts &
173
+ OrderJourneyOrderErrorsCampaignIsInvalidWithOrderedProductsSpecs &
174
+ OrderJourneyOrderErrorsCampaignIsInvalidWithWalletId &
175
+ OrderJourneyOrderErrorsCampaignIsInvalidWithPaymentMethod
176
+
135
177
  // HAPI Backend validation works in this order:
136
178
  // - it validates the campaign first, if campaign itself is not valid, it does not validate the posting requirements at all
137
179
  // - if campaign is valid, then it validates posting requirements
@@ -140,3 +182,24 @@ export type OrderJourneyOrderErrorsCampaignIsInvalid = {
140
182
  export type OrderJourneyOrderErrors =
141
183
  | OrderJourneyOrderErrorsCampaignIsValidButPostingRequirementsInvalid
142
184
  | OrderJourneyOrderErrorsCampaignIsInvalid
185
+
186
+ export type OrderJourneyStepMap = {
187
+ [OrderJourneyStepKey.searchRecommendProducts]: OrderJourneyStep
188
+ [OrderJourneyStepKey.selectProducts]: OrderJourneyStep
189
+ [OrderJourneyStepKey.addContracts]: OrderJourneyStep
190
+ [OrderJourneyStepKey.selectContracts]: OrderJourneyStep
191
+ [OrderJourneyStepKey.basketSummary]: OrderJourneyStep
192
+ [OrderJourneyStepKey.targetGroup]: OrderJourneyStep
193
+ [OrderJourneyStepKey.recruiterInfo]: OrderJourneyStep
194
+ [OrderJourneyStepKey.postingDetails]: OrderJourneyStep
195
+ [OrderJourneyStepKey.postingOrganization]: OrderJourneyStep
196
+ [OrderJourneyStepKey.postingContactInfo]: OrderJourneyStep
197
+ [OrderJourneyStepKey.postingWorkingLocation]: OrderJourneyStep
198
+ [OrderJourneyStepKey.postingURLs]: OrderJourneyStep
199
+ [OrderJourneyStepKey.contractChannelPostingRequirements]: OrderJourneyContractStep[]
200
+ [OrderJourneyStepKey.productChannelPostingRequirements]: OrderJourneyProductStep[]
201
+ [OrderJourneyStepKey.postingUTMCodes]: OrderJourneyStep
202
+ [OrderJourneyStepKey.orderReview]: OrderJourneyStep
203
+ [OrderJourneyStepKey.paymentMethod]: OrderJourneyStep
204
+ [OrderJourneyStepKey.orderConfirmation]: OrderJourneyStep
205
+ }
@@ -2,6 +2,7 @@ import {
2
2
  ZodArray,
3
3
  ZodBoolean,
4
4
  ZodNativeEnum,
5
+ ZodNullable,
5
6
  ZodObject,
6
7
  ZodOptional,
7
8
  ZodRecord,
@@ -21,7 +22,9 @@ export type ZodOrderJourneyStep = ZodObject<{
21
22
  errorMessagesIntlDescriptors: ZodOptional<ZodRecord<ZodString, ZodTypeAny>>
22
23
  }>
23
24
 
24
- export type ZodOrderJourneySteps = ZodArray<ZodOrderJourneyStep>
25
+ export type ZodOrderJourneySteps = ZodUnion<
26
+ [ZodArray<ZodOrderJourneyStep>, ZodArray<ZodArray<ZodOrderJourneyStep>>]
27
+ >
25
28
  export type ZodOrderJourneyUTMCodeMap = ZodObject<{
26
29
  mapToName: ZodBoolean
27
30
  value: ZodString
@@ -43,11 +46,19 @@ export type ZodOrderJourneyOrderReviewStepData = ZodObject<{
43
46
  export type ZodOrderJourneyOrderConfirmationStepData = ZodObject<{
44
47
  disclaimerTexts: ZodArray<ZodString>
45
48
  }>
49
+
50
+ export type ZodOrderJourneyStepKeys = ZodArray<ZodString>
51
+
52
+ export type ZodOrderJourneyStepsEnabled = ZodUnion<
53
+ [ZodOrderJourneyStepKeys, ZodArray<ZodOrderJourneyStepKeys>]
54
+ >
55
+
46
56
  export type WindowHapiValidationsOrderJourney = {
47
57
  supportedStepKeys: OrderJourneyStepKey[]
48
58
  stepKeysRegex: RegExp
49
59
  stepKey: ZodString
50
- stepKeys: ZodArray<ZodString>
60
+ stepKeys: ZodOrderJourneyStepKeys
61
+ stepsEnabled: ZodOrderJourneyStepsEnabled
51
62
  step: ZodOrderJourneyStep
52
63
  steps: ZodOrderJourneySteps
53
64
  paymentMethod: ZodString
package/package.json CHANGED
@@ -1,16 +1,15 @@
1
1
  {
2
2
  "private": false,
3
3
  "name": "@vonq/hapi-elements-types",
4
- "version": "1.22.0",
4
+ "version": "1.24.0",
5
5
  "description": "This package contains Typescript definitions for HAPI Elements",
6
6
  "author": "VONQ HAPI Team",
7
7
  "license": "BSD-3-Clause",
8
8
  "type": "module",
9
9
  "scripts": {
10
10
  "version:minor": "npm version minor",
11
- "build:types": "tsc -d --declarationMap --emitDeclarationOnly",
12
11
  "publish:types": "npm publish --access public",
13
- "generate:index": "cti create ./src"
12
+ "generate:index": "cti create ./"
14
13
  },
15
14
  "main": "index.ts",
16
15
  "types": "index.d.ts",
package/product/index.ts CHANGED
@@ -1,10 +1,10 @@
1
1
  // created from 'create-ts-index'
2
2
 
3
- export * from "./api.types"
4
- export * from "./enums"
5
- export * from "./qa.types"
6
- export * from "./service.types"
7
- export * from "./state.types"
8
- export * from "./types"
9
- export * from "./utils.types"
10
- export * from "./validations.types"
3
+ export * from './api.types';
4
+ export * from './enums';
5
+ export * from './qa.types';
6
+ export * from './service.types';
7
+ export * from './state.types';
8
+ export * from './types';
9
+ export * from './utils.types';
10
+ export * from './validations.types';
@@ -0,0 +1,10 @@
1
+ // created from 'create-ts-index'
2
+
3
+ export * from './api.types';
4
+ export * from './enums';
5
+ export * from './qa.types';
6
+ export * from './service.types';
7
+ export * from './state.types';
8
+ export * from './types';
9
+ export * from './utils.types';
10
+ export * from './validations.types';
package/product/types.ts CHANGED
@@ -47,9 +47,12 @@ export type ProductSupportingContractsPartial = {
47
47
  type: string
48
48
  mc_enabled: boolean
49
49
  }
50
+
51
+ export type ProductAudienceGroup = "niche" | "generic"
52
+
50
53
  export type Product = {
51
54
  allow_orders: boolean
52
- audience_group: "niche" | "generic"
55
+ audience_group: ProductAudienceGroup
53
56
  cross_postings: string[]
54
57
  channel: ProductSupportingContractsPartial
55
58
  bundle_products_ids?: string[]
package/routing/index.ts CHANGED
@@ -1,3 +1,4 @@
1
1
  // created from 'create-ts-index'
2
2
 
3
- export * from "./state.types"
3
+ export * from './state.types';
4
+ export * from './utils.types';
@@ -0,0 +1,4 @@
1
+ // created from 'create-ts-index'
2
+
3
+ export * from './state.types';
4
+ export * from './utils.types';
package/theming/index.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  // created from 'create-ts-index'
2
2
 
3
- export * from "./qa.types"
4
- export * from "./state.types"
5
- export * from "./types"
6
- export * from "./validations.types"
3
+ export * from './qa.types';
4
+ export * from './state.types';
5
+ export * from './types';
6
+ export * from './validations.types';
@@ -0,0 +1,6 @@
1
+ // created from 'create-ts-index'
2
+
3
+ export * from './qa.types';
4
+ export * from './state.types';
5
+ export * from './types';
6
+ export * from './validations.types';
package/theming/types.ts CHANGED
@@ -40,6 +40,7 @@ declare const useTheme: UseThemeFactory<DefaultTheme>
40
40
  export type ThemeGlobalStyles = {
41
41
  borderRadius: string
42
42
  borderColor: string
43
+ placeholderColor: string
43
44
 
44
45
  primaryBackgroundColor: string
45
46
  primaryTextColor: string
@@ -50,18 +51,22 @@ export type ThemeGlobalStyles = {
50
51
  successBackgroundColor: string
51
52
  successTextColor: string
52
53
  successSecondaryBackgroundColor: string
54
+ successSecondaryTextColor: string
53
55
 
54
56
  dangerBackgroundColor: string
55
57
  dangerTextColor: string
56
58
  dangerSecondaryBackgroundColor: string
59
+ dangerSecondaryTextColor: string
57
60
 
58
61
  warningBackgroundColor: string
59
62
  warningTextColor: string
60
63
  warningSecondaryBackgroundColor: string
64
+ warningSecondaryTextColor: string
61
65
 
62
66
  infoBackgroundColor: string
63
67
  infoTextColor: string
64
68
  infoSecondaryBackgroundColor: string
69
+ infoSecondaryTextColor: string
65
70
 
66
71
  fadedBackgroundColor: string
67
72
  fadedTextColor: string
@@ -69,6 +74,9 @@ export type ThemeGlobalStyles = {
69
74
  accentBackgroundColor: string
70
75
  accentTextColor: string
71
76
 
77
+ neutralBackgroundColor: string
78
+ neutralTextColor: string
79
+
72
80
  scrollBarTrackColor: string
73
81
  scrollBarThumbColor: string
74
82
  }
@@ -84,6 +92,7 @@ export type HapiThemeRule =
84
92
  | "loadingSpinner"
85
93
  | "userJourneyBar"
86
94
  | "card"
95
+ | "cardHeader"
87
96
  | "productCard"
88
97
  | "campaignCard"
89
98
  | "tabHeaders"
@@ -103,9 +112,28 @@ export type HapiThemeRule =
103
112
  | "buttonWarningSecondary"
104
113
  | "buttonFaded"
105
114
  | "buttonAccent"
115
+ | "buttonNeutral"
106
116
  | "badgeBase"
117
+ | "badgePrimary"
118
+ | "badgeSecondary"
119
+ | "badgeSuccess"
120
+ | "badgeSuccessSecondary"
121
+ | "badgeInfo"
122
+ | "badgeInfoSecondary"
123
+ | "badgeDanger"
124
+ | "badgeDangerSecondary"
125
+ | "badgeWarning"
126
+ | "badgeWarningSecondary"
127
+ | "badgeFaded"
128
+ | "badgeAccent"
129
+ | "badgeNeutral"
130
+ | "formFieldLabelBase"
107
131
  | "formFieldLabel"
132
+ | "formFieldErrorMessage"
108
133
  | "formFieldBase"
134
+ | "formFieldDescriptionBase"
135
+ | "formFieldDescription"
136
+ | "formFieldErrorMessageBase"
109
137
  | "inputSelectBase"
110
138
  | "input"
111
139
  | "inputRange"
@@ -114,6 +142,19 @@ export type HapiThemeRule =
114
142
  | "textarea"
115
143
  | "select"
116
144
  | "checkbox"
145
+ | "checkboxPrimary"
146
+ | "checkboxSecondary"
147
+ | "checkboxSuccess"
148
+ | "checkboxSuccessSecondary"
149
+ | "checkboxInfo"
150
+ | "checkboxInfoSecondary"
151
+ | "checkboxDanger"
152
+ | "checkboxDangerSecondary"
153
+ | "checkboxWarning"
154
+ | "checkboxWarningSecondary"
155
+ | "checkboxAccent"
156
+ | "checkboxFaded"
157
+ | "checkboxNeutral"
117
158
  | "radio"
118
159
  | "accordionButton"
119
160
  | "accordionArrow"
@@ -141,6 +182,7 @@ export type HapiThemeComponentVariant =
141
182
  | "successSecondary"
142
183
  | "faded"
143
184
  | "accent"
185
+ | "neutral"
144
186
 
145
187
  export type CSSPropertiesInJS = {
146
188
  [key: string]: string | undefined | any[] | (() => any) | any
@@ -165,3 +207,5 @@ export type ThemeFontFaceOption = {
165
207
  fontSize?: string
166
208
  rel?: "stylesheet"
167
209
  }
210
+ export type HapiClassName = (string | undefined)[]
211
+ export type HapiSiteTheme = "elements"
@@ -11,6 +11,8 @@ import {
11
11
 
12
12
  export type ZodThemeGlobalStyles = ZodObject<{
13
13
  borderRadius: ZodString
14
+ borderColor: ZodString
15
+ placeholderColor: ZodString
14
16
 
15
17
  primaryBackgroundColor: ZodString
16
18
  primaryTextColor: ZodString
@@ -20,21 +22,35 @@ export type ZodThemeGlobalStyles = ZodObject<{
20
22
 
21
23
  successBackgroundColor: ZodString
22
24
  successTextColor: ZodString
25
+ successSecondaryBackgroundColor: ZodString
26
+ successSecondaryTextColor: ZodString
23
27
 
24
28
  dangerBackgroundColor: ZodString
25
29
  dangerTextColor: ZodString
30
+ dangerSecondaryBackgroundColor: ZodString
31
+ dangerSecondaryTextColor: ZodString
26
32
 
27
33
  warningBackgroundColor: ZodString
28
34
  warningTextColor: ZodString
35
+ warningSecondaryBackgroundColor: ZodString
36
+ warningSecondaryTextColor: ZodString
29
37
 
30
38
  infoBackgroundColor: ZodString
31
39
  infoTextColor: ZodString
40
+ infoSecondaryBackgroundColor: ZodString
41
+ infoSecondaryTextColor: ZodString
32
42
 
33
43
  fadedBackgroundColor: ZodString
34
44
  fadedTextColor: ZodString
35
45
 
46
+ neutralBackgroundColor: ZodString
47
+ neutralTextColor: ZodString
48
+
36
49
  accentBackgroundColor: ZodString
37
50
  accentTextColor: ZodString
51
+
52
+ scrollBarTrackColor: ZodString
53
+ scrollBarThumbColor: ZodString
38
54
  }>
39
55
 
40
56
  export type ZodFontFace = ZodObject<{
@@ -0,0 +1,3 @@
1
+ // created from 'create-ts-index'
2
+
3
+ export * from './service.types';
package/wallet/index.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  // created from 'create-ts-index'
2
2
 
3
- export * from "./api.types"
4
- export * from "./service.types"
5
- export * from "./state.types"
6
- export * from "./types"
7
- export * from "./validations.types"
3
+ export * from './api.types';
4
+ export * from './service.types';
5
+ export * from './state.types';
6
+ export * from './types';
7
+ export * from './validations.types';
@@ -0,0 +1,7 @@
1
+ // created from 'create-ts-index'
2
+
3
+ export * from './api.types';
4
+ export * from './service.types';
5
+ export * from './state.types';
6
+ export * from './types';
7
+ export * from './validations.types';
@@ -15,7 +15,7 @@ export type WalletState = {
15
15
  paymentIntentRequestBody: WalletPaymentIntentRequest | null
16
16
  paymentIntentClientSecret: string | null
17
17
  topUpIsLoading: boolean
18
- topUpAmount: number
18
+ topUpAmount: number | null
19
19
  topUpMinAmount: number
20
20
  topUpMinAmountCurrency: ProductPriceCurrency
21
21
  topUpTermsOfServiceIsAgreed: boolean
package/wallet/types.ts CHANGED
@@ -30,7 +30,7 @@ export type WalletBillingPortalLinkResponse = {
30
30
  billingPortalLink: string
31
31
  }
32
32
 
33
- export type WalletPaymentIntentPaymentMethod =
33
+ export type WalletStripePaymentMethod =
34
34
  | "card"
35
35
  | "acss_debit"
36
36
  | "affirm"
@@ -59,12 +59,17 @@ export type WalletPaymentIntentPaymentMethod =
59
59
  | "sofort"
60
60
  | "us_bank_account"
61
61
  | "wechat_pay"
62
+ | "customer_balance"
63
+
64
+ export type WalletPaymentIntentPaymentMethod =
65
+ | Omit<WalletStripePaymentMethod, "customer_balance">
62
66
  | "bank_transfer"
63
67
 
64
68
  export type WalletPaymentIntentRequest = {
65
69
  walletId: string
66
70
  partnerId: string
67
71
  amount: number
72
+ currency?: string
68
73
  agreeTerms: boolean
69
74
  draftCampaignId?: string
70
75
  paymentMethodTypes?: WalletPaymentIntentPaymentMethod[]
@@ -1,18 +0,0 @@
1
- import { RawAxiosRequestConfig } from "axios"
2
- import { WindowHapiAPI, WindowHapiAPIModule } from "../_window/api.types"
3
- import { WindowHapiModuleWithConstructorArgs } from "../_window"
4
-
5
- export type WindowHapiAPITalentMindCompanyConfigs = {
6
- getCompanies: RawAxiosRequestConfig
7
- }
8
- export type WindowHapiAPITalentMindCompanyRequests = {
9
- getCompanies: () => Promise<any>
10
- }
11
- export type WindowHapiAPITalentMindCompany =
12
- WindowHapiModuleWithConstructorArgs<
13
- WindowHapiAPIModule<
14
- WindowHapiAPITalentMindCompanyRequests,
15
- WindowHapiAPITalentMindCompanyConfigs
16
- >,
17
- { readonly api: WindowHapiAPI }
18
- >
@@ -1,15 +0,0 @@
1
- import {
2
- HapiServiceFunctionWithLifecycleHooks,
3
- WindowHapiService,
4
- } from "../_window/service.types"
5
- import { WindowHapiModuleWithConstructorArgs } from "../_window"
6
-
7
- export type TalentMindCompanyServiceGetCompaniesHandler = () => Promise<any>
8
-
9
- export type WindowHapiServiceTalentMindCompany =
10
- WindowHapiModuleWithConstructorArgs<
11
- {
12
- getCompanies: HapiServiceFunctionWithLifecycleHooks<TalentMindCompanyServiceGetCompaniesHandler>
13
- },
14
- { readonly service: WindowHapiService }
15
- >
@@ -1,5 +0,0 @@
1
- import { TalentMindCompany } from "./types"
2
-
3
- export type TalentMindCompanyState = {
4
- companies: TalentMindCompany[]
5
- }
@@ -1,6 +0,0 @@
1
- export type TalentMindCompany = {
2
- id: number
3
- name: string
4
- description: string
5
- address: string | null
6
- }
@@ -1,5 +0,0 @@
1
- import { ZodAny, ZodNullable } from "zod"
2
-
3
- export type WindowHapiValidationsTalentMindCompany = {
4
- company: ZodNullable<ZodAny>
5
- }
@@ -1,25 +0,0 @@
1
- import { RawAxiosRequestConfig } from "axios"
2
- import { WindowHapiAPI, WindowHapiAPIModule } from "../_window/api.types"
3
- import { WindowHapiModuleWithConstructorArgs } from "../_window"
4
- import { TalentMindCreateEvaluationForm, TalentMindEvaluation } from "./types"
5
-
6
- export type WindowHapiAPITalentMindEvaluationConfigs = {
7
- getEvaluations: RawAxiosRequestConfig
8
- getEvaluation: RawAxiosRequestConfig
9
- createEvaluation: RawAxiosRequestConfig
10
- }
11
- export type WindowHapiAPITalentMindEvaluationRequests = {
12
- getEvaluations: () => Promise<TalentMindEvaluation[]>
13
- getEvaluation: () => Promise<TalentMindEvaluation>
14
- createEvaluation: (
15
- form: TalentMindCreateEvaluationForm,
16
- ) => Promise<TalentMindEvaluation>
17
- }
18
- export type WindowHapiAPITalentMindEvaluation =
19
- WindowHapiModuleWithConstructorArgs<
20
- WindowHapiAPIModule<
21
- WindowHapiAPITalentMindEvaluationRequests,
22
- WindowHapiAPITalentMindEvaluationConfigs
23
- >,
24
- { readonly api: WindowHapiAPI }
25
- >
@@ -1,25 +0,0 @@
1
- import {
2
- HapiServiceFunctionWithLifecycleHooks,
3
- WindowHapiService,
4
- } from "../_window/service.types"
5
- import { WindowHapiModuleWithConstructorArgs } from "../_window"
6
- import { TalentMindCreateEvaluationForm, TalentMindEvaluation } from "./types"
7
-
8
- export type TalentMindEvaluationServiceGetEvaluationsHandler = () => Promise<
9
- TalentMindEvaluation[]
10
- >
11
- export type TalentMindEvaluationServiceGetEvaluationHandler =
12
- () => Promise<TalentMindEvaluation>
13
- export type TalentMindEvaluationServiceCreateEvaluationHandler = (
14
- resumeForm: TalentMindCreateEvaluationForm,
15
- ) => Promise<TalentMindEvaluation>
16
-
17
- export type WindowHapiServiceTalentMindEvaluation =
18
- WindowHapiModuleWithConstructorArgs<
19
- {
20
- getEvaluations: HapiServiceFunctionWithLifecycleHooks<TalentMindEvaluationServiceGetEvaluationsHandler>
21
- getEvaluation: HapiServiceFunctionWithLifecycleHooks<TalentMindEvaluationServiceGetEvaluationHandler>
22
- createEvaluation: HapiServiceFunctionWithLifecycleHooks<TalentMindEvaluationServiceCreateEvaluationHandler>
23
- },
24
- { readonly service: WindowHapiService }
25
- >
@@ -1,6 +0,0 @@
1
- import { TalentMindCreateEvaluationForm, TalentMindEvaluation } from "./types"
2
-
3
- export type TalentMindEvaluationState = {
4
- evaluations: TalentMindEvaluation[]
5
- evaluationForm: TalentMindCreateEvaluationForm
6
- }