{
  "code": "import RankPan from \"./RankPan\";\r\nexport default class RankSDK {\r\n    constructor() { }\r\n    static ShuShi() {\r\n        if (!Laya.Browser.onWeiXin)\r\n            return;\r\n        this.SetScreen();\r\n        this.RankPan = new RankPan();\r\n        this.RankPan.ShuShi();\r\n    }\r\n    static OpenRank(keyName = \"Level\") {\r\n        if (Laya.Browser.onWeiXin) {\r\n            this.Send(keyName, \"show_friend_rank\");\r\n            console.log(\"打开排行榜---openrank\");\r\n        }\r\n    }\r\n    static Leftpe() {\r\n        if (Laya.Browser.onWeiXin)\r\n            this.Send(\"\", \"show_up_page\");\r\n    }\r\n    static Rightpe() {\r\n        if (Laya.Browser.onWeiXin)\r\n            this.Send(\"\", \"show_next_page\");\r\n    }\r\n    static OpenPan() {\r\n        console.log(\"Laya.Browser.onWeiXin\", Laya.Browser.onWeiXin);\r\n        if (Laya.Browser.window.wx)\r\n            this.RankPan.open();\r\n    }\r\n    static ClosePan() {\r\n        if (Laya.Browser.onWeiXin)\r\n            this.RankPan.close();\r\n    }\r\n    static SetScreen() {\r\n        if (!Laya.Browser.onWeiXin)\r\n            return;\r\n        let width = Laya.stage.width;\r\n        let height = Laya.stage.height;\r\n        let data = { width: width, height: height };\r\n        this.Send(\"\", \"canvase_width_height\", data);\r\n    }\r\n    static Send(keyName, action, data) {\r\n        console.log(\"消息发送成功0---send\");\r\n        Laya.Browser.window.wx.postMessage({\r\n            keyName: keyName,\r\n            action: action,\r\n            data: data\r\n        });\r\n        console.log(\"消息发送成功---send\");\r\n    }\r\n    static SetStage(keyName, value, callBack = null) {\r\n        let obj = [{\r\n                key: keyName,\r\n                value: value\r\n            }];\r\n        Laya.Browser.window.wx.setUserCloudStorage({\r\n            KVDataList: obj,\r\n            success: function (res) {\r\n                console.log(\"数据上传成功\" + res);\r\n                if (callBack) {\r\n                    callBack();\r\n                }\r\n            },\r\n            fail: function (res) {\r\n                console.log(\"数据上传失败\" + res);\r\n                if (callBack) {\r\n                    callBack();\r\n                }\r\n            }\r\n        });\r\n    }\r\n}\r\n//# sourceMappingURL=RankSDK.js.map",
  "references": [
    "E:/LayaProject/2048_laya/src/Rank/RankPan.ts"
  ],
  "map": "{\"version\":3,\"file\":\"RankSDK.js\",\"sourceRoot\":\"\",\"sources\":[\"../../../src/Rank/RankSDK.ts\"],\"names\":[],\"mappings\":\"AACA,OAAO,OAAO,MAAM,WAAW,CAAC;AAC5B,MAAM,CAAC,OAAO,OAAO,OAAO;IAE5B,gBAAiB,CAAC;IAEX,MAAM,CAAC,MAAM;QAChB,IAAG,CAAC,IAAI,CAAC,OAAO,CAAC,QAAQ;YAAC,OAAO;QAEjC,IAAI,CAAC,SAAS,EAAE,CAAC;QACjB,IAAI,CAAC,OAAO,GAAG,IAAI,OAAO,EAAE,CAAC;QAC7B,IAAI,CAAC,OAAO,CAAC,MAAM,EAAE,CAAC;IAC1B,CAAC;IAEM,MAAM,CAAC,QAAQ,CAAC,UAAgB,OAAO;QAC1C,IAAI,IAAI,CAAC,OAAO,CAAC,QAAQ,EAAC;YACtB,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE,kBAAkB,CAAC,CAAC;YACvC,OAAO,CAAC,GAAG,CAAC,kBAAkB,CAAC,CAAC;SACnC;IACL,CAAC;IAOM,MAAM,CAAC,MAAM;QAChB,IAAI,IAAI,CAAC,OAAO,CAAC,QAAQ;YACrB,IAAI,CAAC,IAAI,CAAC,EAAE,EAAE,cAAc,CAAC,CAAC;IACtC,CAAC;IAEM,MAAM,CAAC,OAAO;QACjB,IAAI,IAAI,CAAC,OAAO,CAAC,QAAQ;YACrB,IAAI,CAAC,IAAI,CAAC,EAAE,EAAE,gBAAgB,CAAC,CAAC;IACxC,CAAC;IAOM,MAAM,CAAC,OAAO;QACjB,OAAO,CAAC,GAAG,CAAC,uBAAuB,EAAC,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC;QAC3D,IAAI,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,EAAE;YACtB,IAAI,CAAC,O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