Vasilis

several fixes

......@@ -30,8 +30,8 @@
filePath = "WarplySDKFrameworkIOS/CouponsView.swift"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "212"
endingLineNumber = "212"
startingLineNumber = "218"
endingLineNumber = "218"
landmarkName = "body"
landmarkType = "24">
</BreakpointContent>
......
......@@ -11,9 +11,9 @@ import SwiftUI
@available(iOS 13.0.0, *)
@objc public class CouponBarcodeViewInterface : NSObject {
@objc(couponBarcodeViewController::) static public func couponBarcodeViewController(parentView: UIView?, coupon: Dictionary<String, Any>) -> UIViewController {
return UIHostingController(rootView: CouponBarcodeView(parentView: parentView!, coupon: coupon))
}
// @objc(couponBarcodeViewController::) static public func couponBarcodeViewController(parentView: UIView?, coupon: Dictionary<String, Any>) -> UIViewController {
// return UIHostingController(rootView: CouponBarcodeView(parentView: parentView!, coupon: coupon))
// }
}
......
......@@ -11,8 +11,8 @@ import SwiftUI
@available(iOS 13.0.0, *)
@objc public class CouponViewInterface : NSObject {
@objc(couponViewController::) static public func couponViewController(parentView: UIView?, coupon: Dictionary<String, Any>) -> UIViewController {
return UIHostingController(rootView: CouponView(parentView: parentView!, coupon: coupon))
}
// @objc(couponViewController::) static public func couponViewController(parentView: UIView?, coupon: Dictionary<String, Any>) -> UIViewController {
// return UIHostingController(rootView: CouponView(parentView: parentView!, coupon: coupon))
// }
}
......
......@@ -136,23 +136,29 @@ extension CouponsView {
var body: some View {
HStack {
Button(action: goBack) {
HStack {
Image("ic_back", bundle: Bundle(for: MyEmptyClass.self))
.resizable()
.frame(width: self.uiscreen.height * 0.022, height: self.uiscreen.height * 0.04)
.offset(y: self.uiscreen.height * 0.015)
}
}
HStack(alignment: .center) {
Button {
// Button Action
goBack()
} label: {
Image("ic_back", bundle: Bundle(for: MyEmptyClass.self))
.resizable()
.aspectRatio(contentMode: .fit)
.frame(width: self.uiscreen.height * 0.025, height: self.uiscreen.height * 0.02)
}
Text("Όλα τα κουπόνια μου")
.fontWeight(.medium)
.font(.system(size: 16))
.foregroundColor(Color(red: 0.20784313725490197, green: 0.3176470588235294, blue: 0.40784313725490196))
.frame(width: self.uiscreen.width * 0.8, height: self.uiscreen.height * 0.025, alignment: .center)
.offset( y: self.uiscreen.height * 0.02)
.font(.system(size: 15))
.multilineTextAlignment(.center)
.frame(maxWidth: .infinity)
.padding(.horizontal)
}
.frame(width: self.uiscreen.width, height: self.uiscreen.height * 0.1)
.frame(maxWidth: .infinity)
.padding(.horizontal)
.padding(.vertical, 10)
}
}
......@@ -292,7 +298,7 @@ struct CouponsView: View {
}
.padding(.top, self.uiscreen.height * 0.05)
}
.frame(width:self.uiscreen.width, height:self.uiscreen.height * 0.9 )
.frame(maxWidth: .infinity, maxHeight: .infinity )
.background(
Image("coupons_scrollview", bundle: Bundle(for: MyEmptyClass.self))
.resizable()
......
......@@ -34,21 +34,29 @@ extension MoreForYouView {
var body: some View {
HStack {
Button(action: goBack) {
HStack {
Image("ic_back", bundle: Bundle(for: MyEmptyClass.self))
.resizable()
.frame(width: self.uiscreen.height * 0.022, height: self.uiscreen.height * 0.04)
.offset(y: self.uiscreen.height * 0.015)
}
}
HStack(alignment: .center) {
Button {
// Button Action
goBack()
} label: {
Image("ic_back", bundle: Bundle(for: MyEmptyClass.self))
.resizable()
.aspectRatio(contentMode: .fit)
.frame(width: self.uiscreen.height * 0.025, height: self.uiscreen.height * 0.02)
}
Text("More for you")
.frame(width: self.uiscreen.width * 0.8, height: self.uiscreen.height * 0.025, alignment: .center)
.offset( y: self.uiscreen.height * 0.02)
.font(.system(size: 15))
.fontWeight(.medium)
.font(.system(size: 16))
.foregroundColor(Color(red: 0.20784313725490197, green: 0.3176470588235294, blue: 0.40784313725490196))
.multilineTextAlignment(.center)
.frame(maxWidth: .infinity)
.padding(.horizontal)
}
.frame(width: self.uiscreen.width, height: self.uiscreen.height * 0.1)
.frame(maxWidth: .infinity)
.padding(.horizontal)
.padding(.vertical, 10)
}
}
......@@ -168,7 +176,7 @@ struct MoreForYouView: View {
.padding(.top, self.uiscreen.height * 0.04)
.padding(.bottom, self.uiscreen.height * 0.05)
}
.frame(width:self.uiscreen.width, height:self.uiscreen.height * 0.9 )
.frame(maxWidth: .infinity, maxHeight: .infinity )
.background(
LinearGradient(gradient: Gradient(colors: [Color(hex: 0x1AADCC), Color(hex: 0x83C062)]), startPoint: .top, endPoint: .bottom)
)
......
......@@ -18,8 +18,8 @@
- (void) setToStage;
- (void) setLang:(NSString*) lang;
- (UIViewController *) openCoupons:(UIView*) parentView;
- (UIViewController *) openCoupon:(UIView*) parentView coupon:(NSDictionary*) coupon;
- (UIViewController *) openCouponBarcode:(UIView*) parentView coupon:(NSDictionary*) coupon;
//- (UIViewController *) openCoupon:(UIView*) parentView coupon:(NSDictionary*) coupon;
//- (UIViewController *) openCouponBarcode:(UIView*) parentView coupon:(NSDictionary*) coupon;
- (UIViewController *) openGifts:(UIView*) parentView;
- (UIViewController *) openAllGifts:(UIView*) parentView;
- (UIViewController *) openOldCoupons:(UIView*) parentView;
......
......@@ -53,17 +53,17 @@ NSString *LANG;
return couponsViewController;
}
- (UIViewController *) openCoupon:(UIView*) parentView coupon:(NSDictionary*) coupon {
UIViewController *couponViewController = [CouponViewInterface couponViewController:parentView :coupon];
return couponViewController;
}
- (UIViewController *) openCouponBarcode:(UIView*) parentView coupon:(NSDictionary*) coupon {
UIViewController *couponBarcodeViewController = [CouponBarcodeViewInterface couponBarcodeViewController:parentView :coupon];
return couponBarcodeViewController;
}
//- (UIViewController *) openCoupon:(UIView*) parentView coupon:(NSDictionary*) coupon {
//
// UIViewController *couponViewController = [CouponViewInterface couponViewController:parentView :coupon];
// return couponViewController;
//}
//
//- (UIViewController *) openCouponBarcode:(UIView*) parentView coupon:(NSDictionary*) coupon {
//
// UIViewController *couponBarcodeViewController = [CouponBarcodeViewInterface couponBarcodeViewController:parentView :coupon];
// return couponBarcodeViewController;
//}
- (UIViewController *) openGifts:(UIView*) parentView{
......
......@@ -39,21 +39,29 @@ extension WalletView {
var body: some View {
HStack {
Button(action: goBack) {
HStack {
Image("ic_back", bundle: Bundle(for: MyEmptyClass.self))
.resizable()
.frame(width: self.uiscreen.height * 0.022, height: self.uiscreen.height * 0.02)
.offset(y: self.uiscreen.height * 0.015)
}
}
HStack(alignment: .center) {
Button {
// Button Action
goBack()
} label: {
Image("ic_back", bundle: Bundle(for: MyEmptyClass.self))
.resizable()
.aspectRatio(contentMode: .fit)
.frame(width: self.uiscreen.height * 0.025, height: self.uiscreen.height * 0.02)
}
Text("My loyalty wallet")
.frame(width: self.uiscreen.width * 0.8, height: self.uiscreen.height * 0.025, alignment: .center)
.offset( y: self.uiscreen.height * 0.02)
.font(.system(size: 15))
.fontWeight(.medium)
.font(.system(size: 16))
.foregroundColor(Color(red: 0.20784313725490197, green: 0.3176470588235294, blue: 0.40784313725490196))
.multilineTextAlignment(.center)
.frame(maxWidth: .infinity)
.padding(.horizontal)
}
.frame(width: self.uiscreen.width, height: self.uiscreen.height * 0.1)
.frame(maxWidth: .infinity)
.padding(.horizontal)
.padding(.vertical, 10)
}
}
......@@ -329,7 +337,7 @@ struct WalletView: View {
ScrollView(showsIndicators: false) {
linearView(data: data)
}
.frame(width:self.uiscreen.width, height:self.uiscreen.height * 0.78 )
.frame(maxWidth: .infinity, maxHeight: .infinity )
}
.frame(width:self.uiscreen.width, height:self.uiscreen.height )
......