"use strict";

exports.__esModule = true;
exports["default"] = void 0;
var _flowEventConfig = require("../_com-props/flowEventConfig");
var _locale = require("../../src/locale");
var _setters = require("../_setters");
var _formKeyType = require("../_utils/formKeyType");
var _type = require("../_setters/cBehavior-setter/type");
var _default = exports["default"] = {
  componentName: "Page",
  props: [{
    title: (0, _locale.t)("page.base"),
    display: "accordion",
    type: "group",
    items: [{
      name: 'webGid',
      title: {
        label: (0, _locale.t)('loop-box.key_m1Tbsriyh12Z'),
        tip: (0, _locale.t)('loop-box.key_1srzDzyjKm9i')
      },
      isRequired: true,
      propType: 'string',
      setter: _setters.CStringOnlySetter,
      supportVariable: false
    }, {
      name: "initEnvType",
      title: {
        label: (0, _locale.t)("page.initEnvTypeLabel"),
        tip: (0, _locale.t)("page.initEnvTypeTip")
      },
      setter: {
        componentName: _setters.CSelectSetter,
        props: {
          options: [{
            label: (0, _locale.t)('setter.walletEmailEnvType'),
            value: _type.WalletEnvType.noWallet
          }, {
            label: (0, _locale.t)('setter.walletWEnvType'),
            value: _type.WalletEnvType.wallet
          }]
        }
      }
    }, {
      name: "isWalletConnect",
      title: {
        label: (0, _locale.t)("gridCol.key_CmdPFwsmmH3M"),
        tip: (0, _locale.t)("gridCol.key_CmdPFwsmmH4M")
      },
      propType: "bool",
      setter: "BoolSetter",
      defaultValue: false
    }, {
      name: 'styleWebOS',
      title: {
        label: (0, _locale.t)('gridRow.key_FAr6jUiyP7z4'),
        tip: (0, _locale.t)('gridRow.key_tcUnf2iinPgb')
      },
      propType: 'bool',
      setter: "BoolSetter",
      defaultValue: false
    }, {
      name: "pageDisplay",
      display: "accordion",
      title: {
        label: (0, _locale.t)("page.pageDisplay"),
        tip: (0, _locale.t)("page.pageDisplayTip")
      },
      setter: {
        componentName: "ObjectSetter",
        props: {
          config: {
            items: [{
              name: "display",
              title: {
                label: (0, _locale.t)("page.display"),
                tip: (0, _locale.t)("page.displayTip")
              },
              propType: {
                type: "oneOf",
                value: [_formKeyType.PageDisplayEnum.Normal, _formKeyType.PageDisplayEnum.ByRatio]
              },
              setter: [{
                componentName: "RadioGroupSetter",
                props: {
                  options: [{
                    title: (0, _locale.t)("page.ByRatio"),
                    value: _formKeyType.PageDisplayEnum.ByRatio
                  }, {
                    title: (0, _locale.t)("page.Normal"),
                    value: _formKeyType.PageDisplayEnum.Normal
                  }]
                }
              }, "VariableSetter"],
              defaultValue: _formKeyType.PageDisplayEnum.Normal
            }, {
              name: "width",
              title: {
                label: (0, _locale.t)("page.width") + " (px)",
                tip: (0, _locale.t)("page.widthTip")
              },
              setter: {
                componentName: "NumberSetter",
                props: {
                  step: 1,
                  min: 0
                }
              },
              defaultValue: 1440,
              condition: function condition(target) {
                var type = target.parent.getPropValue("display");
                return type === _formKeyType.PageDisplayEnum.ByRatio;
              }
            }, {
              name: "height",
              title: {
                label: (0, _locale.t)("page.height") + " (px)",
                tip: (0, _locale.t)("page.heightTip")
              },
              setter: {
                componentName: "NumberSetter",
                props: {
                  step: 1,
                  min: 0
                }
              },
              defaultValue: 698,
              condition: function condition(target) {
                var type = target.parent.getPropValue("display");
                return type === _formKeyType.PageDisplayEnum.ByRatio;
              }
            }]
          }
        }
      }
    }, {
      name: "loadingMode",
      title: {
        label: (0, _locale.t)("page.loadingMode"),
        tip: (0, _locale.t)("page.loadingMode")
      },
      setter: {
        componentName: "RadioGroupSetter",
        props: {
          options: [{
            title: (0, _locale.t)("page.loadLevelByLevel"),
            value: _formKeyType.PageLoadingMode.LevelByLevel
          }, {
            title: (0, _locale.t)("page.preloadAll"),
            value: _formKeyType.PageLoadingMode.All
          }, {
            title: (0, _locale.t)("page.preloadFirstLevel"),
            value: _formKeyType.PageLoadingMode.Level1
          }]
        },
        initialValue: _formKeyType.PageLoadingMode.LevelByLevel
      }
    }, (0, _flowEventConfig.getFlowEventConfig)(), (0, _flowEventConfig.getFlowEventConfig)({
      name: "watchParentParamsChangeFV",
      label: (0, _locale.t)('page.watchParentParamsChangeFV'),
      tip: (0, _locale.t)('page.watchParentParamsChangeFVTip'),
      props: {}
    }), (0, _flowEventConfig.getFlowEventConfig)({
      name: "visibilityChangeVisible",
      label: (0, _locale.t)('page.visibilityChangeVisible'),
      tip: (0, _locale.t)('page.visibilityChangeVisibleTip'),
      props: {}
    }), (0, _flowEventConfig.getFlowEventConfig)({
      name: "visibilityChangeHidden",
      label: (0, _locale.t)('page.visibilityChangeHidden'),
      tip: (0, _locale.t)('page.visibilityChangeHiddenTip'),
      props: {}
    })]
  }, {
    title: (0, _locale.t)("page.tgConfig"),
    display: "accordion",
    type: "group",
    items: [{
      name: "headerBackgroundColor",
      title: {
        label: (0, _locale.t)("page.headerBackgroundColor"),
        tip: (0, _locale.t)("page.headerBackgroundColor")
      },
      setter: 'ColorSetter'
    }, {
      name: "bodyBackgroundColor",
      title: {
        label: (0, _locale.t)("page.bodyBackgroundColor"),
        tip: (0, _locale.t)("page.bodyBackgroundColor")
      },
      setter: 'ColorSetter'
    }]
  }, {
    title: (0, _locale.t)("page.advanced"),
    display: "accordion",
    type: "group",
    items: [{
      name: "groupManager",
      title: {
        label: (0, _locale.t)("page.groupManager"),
        tip: (0, _locale.t)("page.groupManagerTip")
      },
      setter: _setters.CGroupManagerSetter
    }]
  }],
  configure: {
    supports: {
      events: false,
      style: true,
      loop: false,
      condition: false
    }
  }
};