@yuno-payments/dashboard-api-mfe 0.36.42 → 0.36.43
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.
- package/build/cjs/index.js +4 -4
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/types/api/api.d.ts +18 -2
- package/build/cjs/types/mutations/checkouts/index.d.ts +1 -0
- package/build/cjs/types/mutations/checkouts/styling/styling.mutation.d.ts +2 -0
- package/build/cjs/types/queries/checkouts/styling/styling.query.d.ts +13 -1
- package/build/cjs/types/types/checkout/styling/styling.d.ts +70 -0
- package/build/esm/index.js +7 -7
- package/build/esm/index.js.map +1 -1
- package/build/esm/types/api/api.d.ts +18 -2
- package/build/esm/types/mutations/checkouts/index.d.ts +1 -0
- package/build/esm/types/mutations/checkouts/styling/styling.mutation.d.ts +2 -0
- package/build/esm/types/queries/checkouts/styling/styling.query.d.ts +13 -1
- package/build/esm/types/types/checkout/styling/styling.d.ts +70 -0
- package/build/index.d.ts +240 -141
- package/package.json +1 -1
|
@@ -8,7 +8,7 @@ import { ChangePaymentsWebhook } from '../mutations';
|
|
|
8
8
|
import { S3Client } from '../types/s3-client';
|
|
9
9
|
import { AllowedList } from '../types/allowed-list';
|
|
10
10
|
import { Cost } from '../types/connection/costs';
|
|
11
|
-
import { Styling, StylingSettings } from '../types/checkout/styling/styling';
|
|
11
|
+
import { Styling, StylingSettings, UpdateStylingThemeParams } from '../types/checkout/styling/styling';
|
|
12
12
|
import { FeatureFlags } from '../types/feature-flags/intex';
|
|
13
13
|
import { FeatureFlagsResult } from '../queries';
|
|
14
14
|
interface S3Payload {
|
|
@@ -213,7 +213,23 @@ export declare class Api extends HttpClient {
|
|
|
213
213
|
getStylingSdkDynamic({ accountCode }: {
|
|
214
214
|
accountCode: any;
|
|
215
215
|
}): Promise<AxiosResponse<Styling.Settings, any>>;
|
|
216
|
-
|
|
216
|
+
/**
|
|
217
|
+
* @deprecated since version 0.36.27. use getStylingSettings instead
|
|
218
|
+
*/
|
|
219
|
+
getStylingTheme({ accountCode }: {
|
|
220
|
+
accountCode: string;
|
|
221
|
+
}): Promise<AxiosResponse<Styling.Theme, any>>;
|
|
222
|
+
/**
|
|
223
|
+
* @deprecated since version 0.36.27. use changeStylingSettings instead
|
|
224
|
+
*/
|
|
225
|
+
updateStylingTheme({ accountCode, theme }: UpdateStylingThemeParams): Promise<AxiosResponse<unknown, any>>;
|
|
226
|
+
/**
|
|
227
|
+
* @deprecated since version 0.36.27. use getStylingSettingsV2 instead
|
|
228
|
+
*/
|
|
229
|
+
getStylingSettings({ accountCode }: {
|
|
230
|
+
accountCode: any;
|
|
231
|
+
}): Promise<AxiosResponse<Styling.Settings, any>>;
|
|
232
|
+
getStylingSettingsV2({ accountCode, environment, }: {
|
|
217
233
|
accountCode: string;
|
|
218
234
|
environment?: string;
|
|
219
235
|
}): Promise<AxiosResponse<StylingSettings.UpdateSettingsResponse, any>>;
|
|
@@ -2,7 +2,19 @@ import { StylingSettings } from '../../../types/checkout/styling/styling';
|
|
|
2
2
|
export declare function useGetStylingSdkDynamic({ accountCode, }: {
|
|
3
3
|
accountCode: string;
|
|
4
4
|
}): import("@tanstack/react-query").UseQueryResult<import("../../../types/checkout/styling/styling").Styling.Settings, unknown>;
|
|
5
|
-
|
|
5
|
+
/**
|
|
6
|
+
* @deprecated since version 0.36.27 use useGetStylingSettingsV2 instead
|
|
7
|
+
*/
|
|
8
|
+
export declare function useGetStylingTheme({ accountCode }: {
|
|
9
|
+
accountCode: string;
|
|
10
|
+
}): import("@tanstack/react-query").UseQueryResult<import("../../../types/checkout/styling/styling").Styling.Theme, unknown>;
|
|
11
|
+
/**
|
|
12
|
+
* @deprecated since version 0.36.27 use useGetStylingSettingsV2 instead
|
|
13
|
+
*/
|
|
14
|
+
export declare function useGetStylingSettings({ accountCode, }: {
|
|
15
|
+
accountCode: string;
|
|
16
|
+
}): import("@tanstack/react-query").UseQueryResult<import("../../../types/checkout/styling/styling").Styling.Settings, unknown>;
|
|
17
|
+
export declare function useGetStylingSettingsV2({ accountCode, environment, }: {
|
|
6
18
|
accountCode: string;
|
|
7
19
|
environment?: string;
|
|
8
20
|
}): import("@tanstack/react-query").UseQueryResult<StylingSettings.UpdateSettingsResponse, unknown>;
|
|
@@ -135,3 +135,73 @@ export declare enum VisualizationMode {
|
|
|
135
135
|
ONE_STEP = "ONE_STEP",
|
|
136
136
|
STEP_BY_STEP = "STEP_BY_STEP"
|
|
137
137
|
}
|
|
138
|
+
/**
|
|
139
|
+
* @deprecated since version 0.36.27. Remove all the code below when new styling section is fully implemented
|
|
140
|
+
*/
|
|
141
|
+
type Mode = 'default';
|
|
142
|
+
interface Spacing {
|
|
143
|
+
top: number;
|
|
144
|
+
right: number;
|
|
145
|
+
bottom: number;
|
|
146
|
+
left: number;
|
|
147
|
+
}
|
|
148
|
+
interface BorderRadius {
|
|
149
|
+
top_left: number;
|
|
150
|
+
top_right: number;
|
|
151
|
+
bottom_right: number;
|
|
152
|
+
bottom_left: number;
|
|
153
|
+
}
|
|
154
|
+
interface Decorator {
|
|
155
|
+
hover: StyleProps;
|
|
156
|
+
disabled: StyleProps;
|
|
157
|
+
focused: StyleProps;
|
|
158
|
+
error: StyleProps;
|
|
159
|
+
}
|
|
160
|
+
type StyleProps = {
|
|
161
|
+
color: string;
|
|
162
|
+
font_family: string;
|
|
163
|
+
font_size: number;
|
|
164
|
+
font_weight: string | number;
|
|
165
|
+
line_height: number;
|
|
166
|
+
padding: Spacing;
|
|
167
|
+
margin: Spacing;
|
|
168
|
+
background_color: string;
|
|
169
|
+
border_radius: BorderRadius;
|
|
170
|
+
decorator: Decorator;
|
|
171
|
+
text_align: string;
|
|
172
|
+
width: number;
|
|
173
|
+
height: number;
|
|
174
|
+
weight: number;
|
|
175
|
+
border_color: string;
|
|
176
|
+
border_style: string;
|
|
177
|
+
border_width: number;
|
|
178
|
+
};
|
|
179
|
+
type Style = {
|
|
180
|
+
props: StyleProps;
|
|
181
|
+
ref: string;
|
|
182
|
+
};
|
|
183
|
+
type Variables = {
|
|
184
|
+
color_primary: string;
|
|
185
|
+
background_color: string;
|
|
186
|
+
};
|
|
187
|
+
interface Section {
|
|
188
|
+
mode: Mode;
|
|
189
|
+
variables?: Variables;
|
|
190
|
+
styles: Style[];
|
|
191
|
+
}
|
|
192
|
+
interface Sections {
|
|
193
|
+
general: Section;
|
|
194
|
+
pm_list: Section;
|
|
195
|
+
apm: Section;
|
|
196
|
+
card_one_step: Section;
|
|
197
|
+
card_step_by_step: Section;
|
|
198
|
+
}
|
|
199
|
+
interface ThemeWithPartialSections {
|
|
200
|
+
account_code: string;
|
|
201
|
+
sections: Partial<Sections>;
|
|
202
|
+
}
|
|
203
|
+
export interface UpdateStylingThemeParams {
|
|
204
|
+
accountCode: string;
|
|
205
|
+
theme: ThemeWithPartialSections;
|
|
206
|
+
}
|
|
207
|
+
export {};
|