@chainplatform/layout 0.2.6 → 0.2.8
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/index.js +2 -0
- package/package.json +1 -1
- package/src/Cart.js +1 -0
- package/src/Layout.js +26 -0
package/index.js
CHANGED
|
@@ -6,6 +6,7 @@ import {
|
|
|
6
6
|
getUserCourseLayout,
|
|
7
7
|
getUserOrderLayout,
|
|
8
8
|
getCourseLearingLayout,
|
|
9
|
+
getCartConfirmLayout,
|
|
9
10
|
getScreenWebinarSize
|
|
10
11
|
} from "./src/Layout";
|
|
11
12
|
import { getCartLayout } from "./src/Cart";
|
|
@@ -20,6 +21,7 @@ export {
|
|
|
20
21
|
getScreenSizeAdmin,
|
|
21
22
|
getScreenSize,
|
|
22
23
|
getCartLayout,
|
|
24
|
+
getCartConfirmLayout,
|
|
23
25
|
getTransactionLayout,
|
|
24
26
|
getCourseLayout,
|
|
25
27
|
getUserCourseLayout,
|
package/package.json
CHANGED
package/src/Cart.js
CHANGED
package/src/Layout.js
CHANGED
|
@@ -173,6 +173,32 @@ export function getTransactionLayout(layoutWidth, isDesktop) {
|
|
|
173
173
|
return view;
|
|
174
174
|
}
|
|
175
175
|
|
|
176
|
+
export function getCartConfirmLayout(layoutWidth, isDesktop, side_bar_width) {
|
|
177
|
+
let viewPadding = 0;
|
|
178
|
+
let viewSplit = sdkStyles.w100pc;
|
|
179
|
+
let borderRadius = 0;
|
|
180
|
+
let marginBottom = setSize(1);
|
|
181
|
+
let sideBarWidth = 0;
|
|
182
|
+
if (isDesktop && layoutWidth > sdkStyles.base_desktop) {
|
|
183
|
+
sideBarWidth = side_bar_width;
|
|
184
|
+
borderRadius = setSize(4);
|
|
185
|
+
marginBottom = setSize(10);
|
|
186
|
+
}
|
|
187
|
+
if (layoutWidth >= sdkStyles.wide_split_desktop) {
|
|
188
|
+
viewSplit = sdkStyles.w50pc;
|
|
189
|
+
}
|
|
190
|
+
if (layoutWidth >= 767) {
|
|
191
|
+
viewPadding = setSize(15);
|
|
192
|
+
}
|
|
193
|
+
let view = {};
|
|
194
|
+
view.viewPadding = viewPadding;
|
|
195
|
+
view.viewSplit = viewSplit;
|
|
196
|
+
view.sideBarWidth = sideBarWidth;
|
|
197
|
+
view.itemBorderRadius = borderRadius;
|
|
198
|
+
view.itemMarginBottom = marginBottom;
|
|
199
|
+
return view;
|
|
200
|
+
}
|
|
201
|
+
|
|
176
202
|
export function getCourseLayout(layoutWidth, isDesktop) {
|
|
177
203
|
let viewSplit = sdkStyles.w100pc;
|
|
178
204
|
let viewPadding = 0;
|