getDislogConfig function

AliAuthModel getDislogConfig()

dialogBottom 为false时 默认水平垂直居中 如果需要修改弹窗的圆角背景可修改android/app/src/main/res/drawable/dialog_background_color.xml 文件 'appPrivacyOne'、'appPrivacyTwo' 字段中的逗号拼接处请勿使用多余的空格,以免出现未知错误

Implementation

AliAuthModel getDislogConfig() {
  final screenWidth =
      (window.physicalSize.width / window.devicePixelRatio * 0.8).floor();
  final screenHeight =
      (window.physicalSize.height / window.devicePixelRatio * 0.65).floor();
  int logBtnOffset = (screenHeight / 2).floor();
  return AliAuthModel.fromJson({
    'isDialog': true,
    'isDebug': true,
    'customPageBackgroundLyout': false,
    'isPrivacyAnimation': false,
    'privacyVCIsCustomized': false,
    'isHiddenCustom': true,
    'statusBarColor': "#00000000",
    'statusBarHidden': true,
    'statusBarUIFlag': -1,
    'lightColor': true,
    'navColor': "#ff00ff",
    'navText': '一键登录',
    'navTextColor': "#333333",
    'navTextSize': -1,
    'navReturnImgPath': 'icon_close',
    'navReturnImgWidth': 30,
    'navReturnImgHeight': 30,
    'navReturnHidden': false,
    'navHidden': false,
    'logoHidden': false,
    'logoImgPath': 'assets/taobao.png',
    'logoWidth': 48,
    'logoHeight': 48,
    'logoOffsetY': 20,
    'logoScaleType': "CENTER",
    'sloganHidden': false,
    'sloganText': '一键登录欢迎语',
    'sloganTextColor': "#555555",
    'sloganTextSize': 11,
    'sloganOffsetY': logBtnOffset - 100,
    'numberColor': "#555fff",
    'numberSize': 15,
    'numFieldOffsetY': logBtnOffset - 50,
    'logBtnText': '一键登录',
    'logBtnTextColor': '#ffffff',
    'logBtnTextSize': 16,
    'logBtnHeight': 38,
    'logBtnMarginLeftAndRight': 15,
    'logBtnBackgroundPath':
        'assets/login_btn_normal.png,assets/login_btn_unable.png,assets/login_btn_press.png',
    'logBtnOffsetY': logBtnOffset,
    'loadingImgPath': '',
    'appPrivacyOne': '思预云用户协议,https://www.baidu.com',
    'appPrivacyTwo': '用户隐私,https://www.baidu.com',
    'appPrivacyColor': '#445588,#3971fe',
    'privacyState': false,
    'protocolGravity': 0,
    'privacyTextSize': 11,
    'privacyMargin': 20,
    'checkBoxWH': 17,
    'changeBtnTitle': '切换到其他',
    'changeBtnTitleSize': 18,
    'changeBtnTitleColor': '#ff0000',
    'changeBtnIsHidden': false,
    'vendorPrivacyPrefix': '《',
    'vendorPrivacySuffix': '》',
    'protocolLayoutGravity': 10,
    'switchAccTextSize': 11,
    'switchOffsetY': logBtnOffset + 50,
    'customThirdImgPaths':
        'assets/taobao.png,assets/tianmao.png,assets/taobao.png',
    'customThirdImgWidth': 40,
    'customThirdImgHeight': 40,
    'customThirdImgSpace': 20,
    'customThirdImgOffsetY': 20,
    'authPageActIn': 'in_activity,out_activity',
    'authPageActOut': 'in_activity,out_activity',
    'pageBackgroundPath': 'dialog_background_color',
    'dialogAlpha': 0.5,
    'dialogWidth': screenWidth,
    'dialogHeight': screenHeight,
    'dialogOffsetX': -1,
    'dialogOffsetY': -1,
    'dialogBottom': false,
    'alertBarIsHidden': false,
    'alertTitleBarColor': '#ffffff',
    'alertCloseItemIsHidden': false,
    'alertCloseImage': 'assets/close.png',
    'alertCloseImageX': 10,
    'alertCloseImageY': 10,
    'alertCloseImageW': 10,
    'alertCloseImageH': 10,
    'alertBlurViewColor': '#000',
    'alertBlurViewAlpha': 0.7,
    'alertCornerRadiusArray': '10,10,10,10',
  });
}