@heybox/hb-sdk 0.8.3-alpha.3 → 0.8.3-alpha.5
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/CHANGELOG.md +26 -1
- package/README.md +8 -6
- package/dist/cli-chunks/{build-Dydd4Rzd.cjs → build-8dIKgG1v.cjs} +5 -5
- package/dist/cli-chunks/{context-DcuY0bGO.cjs → context-DSNBFwsG.cjs} +35 -8
- package/dist/cli-chunks/{create-DKVTlorM.cjs → create-DmNfBoq7.cjs} +1 -1
- package/dist/cli-chunks/{dev-DbrUeTqi.cjs → dev-C15G1TxE.cjs} +194 -73
- package/dist/cli-chunks/{doctor-D184dg_h.cjs → doctor-r6m7pK1R.cjs} +1 -1
- package/dist/cli-chunks/{index-B_HjHK3d.cjs → index-B6lVqj5W.cjs} +15 -15
- package/dist/cli-chunks/{index-BG8JJ9pA.cjs → index-CsQ1g-cL.cjs} +2 -2
- package/dist/cli-chunks/{index.esm-42g2R7qD.cjs → index.esm-DG1EUOV-.cjs} +7 -7
- package/dist/cli-chunks/{login-D3MBcgNb.cjs → login-DOUitUrc.cjs} +2 -2
- package/dist/cli-chunks/{project-vite-CUh6Dsv5.cjs → project-vite-C-YGhyHJ.cjs} +1 -1
- package/dist/cli-chunks/{remote-EBGDOJL3.cjs → remote-i3QX7A-u.cjs} +36 -9
- package/dist/cli-chunks/{runtime-gate-CE1ln9xc.cjs → runtime-gate-hlz0xgg8.cjs} +1 -1
- package/dist/cli-chunks/{runtime-permission-env-CVt4QPbX.cjs → runtime-permission-env-DNXaBBHz.cjs} +119 -6
- package/dist/cli-chunks/{session-CKuEz-ih.cjs → session-u4BpZqwE.cjs} +1 -1
- package/dist/cli-chunks/{skill-oLEQS_U6.cjs → skill-DAOCq0eg.cjs} +2 -2
- package/dist/cli-chunks/{version-BNNxfn8M.cjs → version-MrIy1W5p.cjs} +1 -1
- package/dist/cli.cjs +1 -1
- package/dist/devtools/browser-dev-host/assets/browser-dev-host-CJDZz8aw.js +101 -0
- package/dist/devtools/browser-dev-host/assets/{desktop-app-launch-EnOYLhEx.js → desktop-app-launch-BbRQb08Y.js} +3 -3
- package/dist/devtools/browser-dev-host/assets/{index-8YA6OLi7.js → index-8N4og21f.js} +4 -4
- package/dist/devtools/browser-dev-host/assets/index-BrXEMo2-.css +1 -0
- package/dist/devtools/browser-dev-host/index.html +3 -3
- package/dist/index.cjs.js +16 -16
- package/dist/index.esm.js +16 -16
- package/dist/protocol.cjs.js +20 -20
- package/dist/protocol.esm.js +20 -20
- package/dist/vite.cjs.js +3 -3
- package/dist/vite.esm.js +3 -3
- package/docs/runtime-host-migration.md +6 -4
- package/package.json +5 -5
- package/skill/skill.json +4 -4
- package/types/protocol/dev-session.d.ts +13 -2
- package/dist/devtools/browser-dev-host/assets/browser-dev-host-u03IcCCS.js +0 -101
- package/dist/devtools/browser-dev-host/assets/index-D-cRoNV5.css +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.hb-avatar{position:relative;box-sizing:border-box;display:inline-flex;flex-shrink:0}.hb-avatar__clip{display:flex;align-items:center;justify-content:center;width:100%;height:100%;overflow:hidden;background:var(--hb-color-bg-surface);border-radius:50%}.hb-avatar__img{display:block;width:100%;height:100%;object-fit:cover}.hb-avatar__fallback{width:66%;height:66%;fill:var(--hb-color-icon-tertiary)}.hb-avatar--logged-out .hb-avatar__fallback{fill:var(--hb-color-icon-disabled)}.hb-avatar__frame{position:absolute;top:50%;left:50%;width:135.3%;height:135.3%;object-fit:contain;pointer-events:none;transform:translate(-50%,-50%)}.hb-v2-icon{display:inline-flex;align-items:center;justify-content:center;flex-shrink:0;width:1em;height:1em;line-height:1;color:inherit;vertical-align:-.125em}.hb-v2-icon svg{display:block;width:1em;height:1em;fill:currentColor;vertical-align:0}.hb-v2-icon svg [stroke]:not([stroke=none]){stroke:currentColor}.hb-v2-icon svg [fill]:not([fill=none]){fill:currentColor}.hb-v2-icon--spin svg{animation:hb-v2-icon-spin 1s linear infinite}@keyframes hb-v2-icon-spin{to{transform:rotate(1turn)}}.hb-v2-toast__wrapper{position:fixed;inset:0;display:flex;align-items:center;justify-content:center;box-sizing:border-box;pointer-events:none}.hb-v2-toast{display:flex;align-items:center;justify-content:center;box-sizing:border-box;margin:0;font-family:PingFang SC,Helvetica Neue,Arial,sans-serif;font-size:13px;font-weight:400;line-height:17px;letter-spacing:0;text-align:center;pointer-events:auto}.hb-v2-toast__wrapper-click-through .hb-v2-toast{pointer-events:none}.hb-v2-toast-default,.hb-v2-toast-loading{flex-direction:column;gap:10px;min-width:92px;min-height:91px;max-width:220px;padding:20px;color:var(--hb-color-text-inverse);background:var(--hb-color-bg-toast);border-radius:12px;-webkit-backdrop-filter:blur(12.5px);backdrop-filter:blur(12.5px)}.hb-v2-toast-loading{min-height:101px}.hb-v2-toast-loading-icon-only{gap:0;min-width:0;min-height:0;width:74px;height:74px;padding:20px}.hb-v2-toast__icon{font-size:24px;line-height:24px}.hb-v2-toast__text{position:relative;z-index:1;max-width:180px;color:inherit;overflow-wrap:break-word}.hb-v2-toast__spinner{display:flex;align-items:center;justify-content:center;width:34px;height:34px}.hb-v2-toast__spinner-circular{display:block;width:34px;height:34px;animation:hb-v2-toast-loading-rotate 2s linear infinite}.hb-v2-toast__spinner-bg{stroke:var(--hb-color-game-record-white-30);stroke-width:2.5}.hb-v2-toast__spinner-path{stroke:var(--hb-color-game-record-white-100);stroke-linecap:round;stroke-width:2.5;animation:hb-v2-toast-spin-round 1.5s linear infinite}.hb-v2-toast-fade-enter-active,.hb-v2-toast-fade-leave-active{transition:opacity .16s cubic-bezier(0,0,.58,1)}.hb-v2-toast-fade-enter-from,.hb-v2-toast-fade-leave-to{opacity:0}@keyframes hb-v2-toast-loading-rotate{to{transform:rotate(1turn)}}@keyframes hb-v2-toast-spin-round{0%{stroke-dasharray:20,132;stroke-dashoffset:0}50%{stroke-dasharray:90,62;stroke-dashoffset:-60px}to{stroke-dasharray:20,132;stroke-dashoffset:-152px}}.splitpanes{width:100%;height:100%;display:flex}.splitpanes--vertical{flex-direction:row}.splitpanes--horizontal{flex-direction:column}.splitpanes--dragging .splitpanes__pane{-webkit-user-select:none;user-select:none;pointer-events:none}:has(.splitpanes--dragging){-webkit-user-select:none;user-select:none;pointer-events:none}.splitpanes__pane{width:100%;height:100%;overflow:hidden}.splitpanes--ready .splitpanes__pane{will-change:width,height;transition:width .2s ease-out,height .2s ease-out}.splitpanes--ready.splitpanes--dragging .splitpanes__pane{transition:none}.splitpanes__splitter{touch-action:none}.splitpanes__splitter:focus{outline:none}.splitpanes--vertical>.splitpanes__splitter{cursor:col-resize;min-width:1px}.splitpanes--horizontal>.splitpanes__splitter{cursor:row-resize;min-height:1px}.default-theme.splitpanes .splitpanes__pane{background-color:#f2f2f2}.default-theme.splitpanes .splitpanes__splitter{box-sizing:border-box;background-color:#fff;flex-shrink:0;position:relative}.default-theme.splitpanes .splitpanes__splitter:focus-visible{outline-offset:-2px;outline:2px solid #3b82f6}.default-theme.splitpanes .splitpanes__splitter:before,.default-theme.splitpanes .splitpanes__splitter:after{content:"";background-color:#00000026;transition:background-color .3s;position:absolute;top:50%;left:50%}.default-theme.splitpanes .splitpanes__splitter:hover:before,.default-theme.splitpanes .splitpanes__splitter:hover:after{background-color:#00000040}.default-theme.splitpanes .splitpanes__splitter:first-child{cursor:auto}.default-theme.splitpanes .splitpanes .splitpanes__splitter{z-index:1}.default-theme.splitpanes--vertical>.splitpanes__splitter,.default-theme .splitpanes--vertical>.splitpanes__splitter{border-left:1px solid #eee;width:7px;margin-left:-1px}.default-theme.splitpanes--vertical>.splitpanes__splitter:before,.default-theme.splitpanes--vertical>.splitpanes__splitter:after,.default-theme .splitpanes--vertical>.splitpanes__splitter:before,.default-theme .splitpanes--vertical>.splitpanes__splitter:after{width:1px;height:30px;transform:translateY(-50%)}.default-theme.splitpanes--vertical>.splitpanes__splitter:before,.default-theme .splitpanes--vertical>.splitpanes__splitter:before{margin-left:-2px}.default-theme.splitpanes--vertical>.splitpanes__splitter:after,.default-theme .splitpanes--vertical>.splitpanes__splitter:after{margin-left:1px}.default-theme.splitpanes--horizontal>.splitpanes__splitter,.default-theme .splitpanes--horizontal>.splitpanes__splitter{border-top:1px solid #eee;height:7px;margin-top:-1px}.default-theme.splitpanes--horizontal>.splitpanes__splitter:before,.default-theme.splitpanes--horizontal>.splitpanes__splitter:after,.default-theme .splitpanes--horizontal>.splitpanes__splitter:before,.default-theme .splitpanes--horizontal>.splitpanes__splitter:after{width:30px;height:1px;transform:translate(-50%)}.default-theme.splitpanes--horizontal>.splitpanes__splitter:before,.default-theme .splitpanes--horizontal>.splitpanes__splitter:before{margin-top:-2px}.default-theme.splitpanes--horizontal>.splitpanes__splitter:after,.default-theme .splitpanes--horizontal>.splitpanes__splitter:after{margin-top:1px}.dev-readiness[data-v-5831762c]{padding:8px 12px;color:var(--hb-color-text-secondary);border-bottom:1px solid rgba(31,35,41,.09);font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:11px;line-height:16px;letter-spacing:0px}.dev-readiness .dev-readiness__entry[data-v-5831762c],.dev-readiness .dev-readiness__artifact[data-v-5831762c]{margin:4px 0;overflow-wrap:anywhere}.dev-readiness .dev-readiness__reason[data-v-5831762c]{display:block}.local-permissions[data-v-fa5ef821]{padding:8px 12px;color:var(--hb-color-text-secondary);background:#fff8e6;border-bottom:1px solid rgba(31,35,41,.09);font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:11px;line-height:16px;letter-spacing:0px}.local-permissions .local-permissions__warning[data-v-fa5ef821],.local-permissions .local-permissions__entry[data-v-fa5ef821]{margin:4px 0;overflow-wrap:anywhere}.sandbox-panel[data-v-9ee5b18d]{padding:12px;height:100%;overflow:auto;font-size:12px;color:#666}.sandbox-panel select[data-v-9ee5b18d]{width:100%;padding:6px}.sandbox-panel__toolbar[data-v-9ee5b18d]{display:flex;align-items:center;gap:8px;margin:12px 0}.sandbox-panel__toolbar span[data-v-9ee5b18d]{flex:1;overflow-wrap:anywhere}.sandbox-panel button[data-v-9ee5b18d]{background:transparent;border:0;padding:6px;cursor:pointer;color:inherit}.sandbox-panel__entry[data-v-9ee5b18d]{display:flex;gap:8px;width:100%;text-align:left;overflow-wrap:anywhere}.sandbox-panel button[data-v-9ee5b18d]:disabled{cursor:default}.workbench-log-filters{display:grid;gap:9px}.workbench-log-filters select{flex:1;min-width:0;height:28px;border:1px solid var(--hb-color-border-muted);border-radius:5px;color:var(--hb-color-text-secondary);background:var(--hb-color-bg-surface);font:inherit}.workbench-log-filters fieldset{display:grid;grid-template-columns:1fr 1fr;margin:0;padding:0;border:0;gap:2px 6px}.workbench-log-filters legend{grid-column:1/-1;width:100%;padding:2px 4px 4px;color:var(--hb-color-text-tertiary);font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:10px;line-height:13px;letter-spacing:0px}.workbench-log-filters label{display:flex;min-width:0;min-height:28px;align-items:center;padding:0 4px;border-radius:5px;color:var(--hb-color-text-secondary);gap:6px;cursor:pointer;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:11px;line-height:16px;letter-spacing:0px}.workbench-log-filters label:hover{background:var(--hb-color-bg-subtle)}.workbench-log-filters input{width:14px;height:14px;margin:0;accent-color:var(--hb-color-brand-primary)}.workbench-log-filters__reset{justify-self:end;min-height:28px;padding:0 7px;border:0;border-radius:5px;color:var(--hb-color-brand-primary);background:transparent;cursor:pointer;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:11px;line-height:16px;letter-spacing:0px}.workbench-log-filters__reset:hover:not(:disabled){background:var(--hb-color-bg-subtle)}.workbench-log-filters__reset:disabled{color:var(--hb-color-text-tertiary);cursor:default}.workbench-log-row{border-left:2px solid transparent}.workbench-log-row:hover,.workbench-log-row[open]{background:var(--hb-color-bg-subtle)}.workbench-log-row[data-level=warn]{border-left-color:#d97a06;background:#d97a0614}.workbench-log-row[data-level=error]{border-left-color:var(--hb-color-status-danger);background:#da2a2a14}.workbench-log-row__summary{display:grid;grid-template-columns:minmax(0,1fr) 13px;align-items:start;padding:6px 8px;gap:6px;cursor:pointer;list-style:none}.workbench-log-row__summary::-webkit-details-marker{display:none}.workbench-log-row__indicator{width:6px;height:6px;margin-top:5px;border-radius:50%;background:var(--hb-color-text-tertiary)}.workbench-log-row[data-level=info] .workbench-log-row__indicator{background:#2679d9}.workbench-log-row[data-level=warn] .workbench-log-row__indicator{background:#d97a06}.workbench-log-row[data-level=error] .workbench-log-row__indicator{background:var(--hb-color-status-danger)}.workbench-log-row__content{display:grid;min-width:0;gap:3px}.workbench-log-row__primary,.workbench-log-row__secondary{display:flex;min-width:0;align-items:center;gap:6px}.workbench-log-row__source{flex:0 0 auto;color:var(--hb-color-text-tertiary);font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:10px;line-height:13px;letter-spacing:0px}.workbench-log-row__method{flex:1 1 auto;min-width:0;overflow:hidden;color:var(--hb-color-text-tertiary);text-overflow:ellipsis;white-space:nowrap;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:10px;line-height:13px;letter-spacing:0px}.workbench-log-row__message{flex:1 1 auto;min-width:0;color:var(--hb-color-text-primary);white-space:pre-wrap;overflow-wrap:anywhere;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:11px;line-height:16px;letter-spacing:0px}.workbench-log-row__outcome,.workbench-log-row__duration,.workbench-log-row__repeat{flex:0 0 auto;color:var(--hb-color-text-tertiary);font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:10px;line-height:13px;letter-spacing:0px}.workbench-log-row__outcome[data-outcome=success]{color:#16865b}.workbench-log-row__outcome[data-outcome=error],.workbench-log-row__outcome[data-outcome=denied]{color:var(--hb-color-status-danger)}.workbench-log-row__time{margin-top:1px;color:var(--hb-color-text-tertiary);white-space:nowrap;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:10px;line-height:13px;letter-spacing:0px}.workbench-log-row__chevron{margin-top:2px;color:var(--hb-color-text-tertiary);transition:transform .15s ease}.workbench-log-row[open] .workbench-log-row__chevron{transform:rotate(90deg)}.workbench-log-row__details{position:relative;padding:0 8px 8px}.workbench-log-row__metadata{display:flex;min-height:24px;align-items:center;padding-right:36px;color:var(--hb-color-text-tertiary);gap:10px;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:10px;line-height:13px;letter-spacing:0px}.workbench-log-row__details pre{max-height:220px;margin:0;overflow:auto;padding:8px 10px;border:1px solid var(--hb-color-border-muted);border-radius:6px;color:var(--hb-color-text-secondary);background:var(--hb-color-bg-surface);white-space:pre-wrap;overflow-wrap:anywhere;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:10px;line-height:13px;letter-spacing:0px}.workbench-log-row__details .workbench-icon-button{position:absolute;top:0;right:5px}.workbench-log-row__source,.workbench-log-row__method,.workbench-log-row__message,.workbench-log-row__outcome,.workbench-log-row__duration,.workbench-log-row__repeat,.workbench-log-row__time,.workbench-log-row__metadata,.workbench-log-row__details pre{font-family:var(--hb-sdk-workbench-font-mono);font-variant-numeric:tabular-nums}:root{--hb-sdk-workbench-control-size: 32px;--hb-sdk-workbench-control-radius: 8px;--hb-sdk-workbench-font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Monaco, Consolas, "Liberation Mono", monospace;--hb-sdk-workbench-menu-radius: 10px}.workbench-icon-button{position:relative;display:grid;width:var(--hb-sdk-workbench-control-size);height:var(--hb-sdk-workbench-control-size);padding:0;place-items:center;border:1px solid var(--hb-color-border-muted);border-radius:var(--hb-sdk-workbench-control-radius);color:var(--hb-color-text-primary);background:var(--hb-color-bg-page);box-shadow:none;cursor:pointer;outline:none;transition:border-color .15s ease,background .15s ease,box-shadow .15s ease}.workbench-icon-button:hover,.workbench-icon-button[data-state=open]{background:var(--hb-color-bg-subtle)}.workbench-icon-button:focus-visible{border-color:var(--hb-color-brand-primary);box-shadow:0 0 0 2px #006ef429}.workbench-icon-button:disabled,.workbench-icon-button[aria-disabled=true]{color:var(--hb-color-text-tertiary);cursor:not-allowed}.workbench-icon-button[data-variant=ghost]{border-color:transparent;background:transparent}.workbench-icon-button[data-variant=glass]{border-color:#ffffffbf;border-radius:50%;background:#ffffff9e;box-shadow:0 7px 22px #1f232924,inset 0 0 0 .5px #fffc;-webkit-backdrop-filter:blur(16px) saturate(1.4);backdrop-filter:blur(16px) saturate(1.4)}.workbench-tooltip{z-index:50;padding:5px 7px;border-radius:5px;color:#fff;background:#191b1feb;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:10px;line-height:13px;letter-spacing:0px}.workbench-popover{z-index:30;display:grid;width:270px;padding:14px;border:1px solid rgba(31,35,41,.09);border-radius:var(--hb-sdk-workbench-menu-radius);gap:10px;background:#fffffff5;box-shadow:0 18px 48px #1f23292e;outline:none;-webkit-backdrop-filter:blur(22px);backdrop-filter:blur(22px)}.workbench-popover--compact{width:220px;padding:10px;gap:4px}.workbench-popover__heading{padding:0 2px;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:13px;line-height:17px;letter-spacing:0px}.workbench-menu-item{display:flex;min-width:0;min-height:34px;align-items:center;justify-content:space-between;padding:0 8px;border:0;border-radius:6px;color:var(--hb-color-text-primary);background:transparent;cursor:pointer;outline:none;text-decoration:none;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:12px;line-height:16px;letter-spacing:0px}.workbench-menu-item:hover,.workbench-menu-item:focus-visible,.workbench-menu-item[data-selected=true]{background:var(--hb-color-bg-subtle)}.workbench-menu-item:focus-visible{box-shadow:inset 0 0 0 1px var(--hb-color-brand-primary)}.workbench-menu-item[aria-disabled=true]{color:var(--hb-color-text-tertiary);cursor:not-allowed}.workbench-menu-item__label{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:root{--hb-radius-xs: 2px;--hb-radius-s: 3px;--hb-radius-m: 5px;--hb-radius-l: 8px;--hb-radius-xl: 12px;--hb-space-4: 4px;--hb-space-8: 8px;--hb-space-10: 10px;--hb-space-page-gutter: 12px;--hb-color-icon-primary: #14191e;--hb-color-icon-secondary: #64696e;--hb-color-icon-tertiary: #8c9196;--hb-color-icon-disabled: #c8cdd2;--hb-color-icon-inverse: #ffffff;--hb-color-text-primary: #14191e;--hb-color-text-secondary: #64696e;--hb-color-text-tertiary: #8c9196;--hb-color-text-placeholder: #c8cdd2;--hb-color-text-inverse: #ffffff;--hb-color-border-default: #f3f4f5;--hb-color-border-muted: #f1f2f3;--hb-color-border-strong: #dadde0;--hb-color-border-section: #fafbfc;--hb-color-border-inverse: #ffffff;--hb-color-bg-page: #ffffff;--hb-color-bg-surface: #fafbfc;--hb-color-bg-subtle: #f7f8f9;--hb-color-bg-muted: #f3f4f5;--hb-color-bg-raised: #f1f2f3;--hb-color-bg-chat: #f1f2f3;--hb-color-bg-control-secondary: #e7e8e9;--hb-color-bg-chat-bubble: #c4e4fc;--hb-color-bg-toast: rgba(57, 61, 64, .8980392157);--hb-color-bg-popmask: rgba(0, 0, 0, .5019607843);--hb-color-action-link: #004b96;--hb-color-action-link-subtle: rgba(0, 75, 150, .1019607843);--hb-color-brand-primary: #006ef4;--hb-color-status-danger: #fa3c4b;--hb-color-status-success: #32b846;--hb-color-game-price-coupon: #f67010;--hb-color-game-price-low: #32b846;--hb-color-game-price-new-low: #009015;--hb-color-platform-playstation: #0071ce;--hb-color-platform-steam: #021930;--hb-color-platform-switch: #e70012;--hb-color-platform-windows: #81bc0d;--hb-color-platform-xbox: #0f7c10;--hb-color-game-record-white-01: rgba(255, 255, 255, .01);--hb-color-game-record-black-01: rgba(0, 0, 0, .01);--hb-color-game-record-white-02: rgba(255, 255, 255, .02);--hb-color-game-record-black-02: rgba(0, 0, 0, .02);--hb-color-game-record-white-03: rgba(255, 255, 255, .03);--hb-color-game-record-black-03: rgba(0, 0, 0, .03);--hb-color-game-record-white-05: rgba(255, 255, 255, .05);--hb-color-game-record-black-05: rgba(0, 0, 0, .05);--hb-color-game-record-white-08: rgba(255, 255, 255, .08);--hb-color-game-record-black-08: rgba(0, 0, 0, .08);--hb-color-game-record-white-10: rgba(255, 255, 255, .1);--hb-color-game-record-black-10: rgba(0, 0, 0, .1);--hb-color-game-record-white-15: rgba(255, 255, 255, .15);--hb-color-game-record-black-15: rgba(0, 0, 0, .15);--hb-color-game-record-white-20: rgba(255, 255, 255, .2);--hb-color-game-record-black-20: rgba(0, 0, 0, .2);--hb-color-game-record-white-30: rgba(255, 255, 255, .3);--hb-color-game-record-black-30: rgba(0, 0, 0, .3);--hb-color-game-record-white-40: rgba(255, 255, 255, .4);--hb-color-game-record-black-40: rgba(0, 0, 0, .4);--hb-color-game-record-white-50: rgba(255, 255, 255, .5);--hb-color-game-record-black-50: rgba(0, 0, 0, .5);--hb-color-game-record-white-60: rgba(255, 255, 255, .6);--hb-color-game-record-black-60: rgba(0, 0, 0, .6);--hb-color-game-record-white-70: rgba(255, 255, 255, .7);--hb-color-game-record-black-70: rgba(0, 0, 0, .7);--hb-color-game-record-white-80: rgba(255, 255, 255, .8);--hb-color-game-record-black-80: rgba(0, 0, 0, .8);--hb-color-game-record-white-85: rgba(255, 255, 255, .85);--hb-color-game-record-black-85: rgba(0, 0, 0, .85);--hb-color-game-record-white-90: rgba(255, 255, 255, .9);--hb-color-game-record-black-90: rgba(0, 0, 0, .9);--hb-color-game-record-white-100: #ffffff;--hb-color-game-record-black-100: #000000;color-scheme:light}:root[data-hb-theme=light]{--hb-color-icon-primary: #14191e;--hb-color-icon-secondary: #64696e;--hb-color-icon-tertiary: #8c9196;--hb-color-icon-disabled: #c8cdd2;--hb-color-icon-inverse: #ffffff;--hb-color-text-primary: #14191e;--hb-color-text-secondary: #64696e;--hb-color-text-tertiary: #8c9196;--hb-color-text-placeholder: #c8cdd2;--hb-color-text-inverse: #ffffff;--hb-color-border-default: #f3f4f5;--hb-color-border-muted: #f1f2f3;--hb-color-border-strong: #dadde0;--hb-color-border-section: #fafbfc;--hb-color-border-inverse: #ffffff;--hb-color-bg-page: #ffffff;--hb-color-bg-surface: #fafbfc;--hb-color-bg-subtle: #f7f8f9;--hb-color-bg-muted: #f3f4f5;--hb-color-bg-raised: #f1f2f3;--hb-color-bg-chat: #f1f2f3;--hb-color-bg-control-secondary: #e7e8e9;--hb-color-bg-chat-bubble: #c4e4fc;--hb-color-bg-toast: rgba(57, 61, 64, .8980392157);--hb-color-bg-popmask: rgba(0, 0, 0, .5019607843);--hb-color-action-link: #004b96;--hb-color-action-link-subtle: rgba(0, 75, 150, .1019607843);--hb-color-brand-primary: #006ef4;--hb-color-status-danger: #fa3c4b;--hb-color-status-success: #32b846;--hb-color-game-price-coupon: #f67010;--hb-color-game-price-low: #32b846;--hb-color-game-price-new-low: #009015;--hb-color-platform-playstation: #0071ce;--hb-color-platform-steam: #021930;--hb-color-platform-switch: #e70012;--hb-color-platform-windows: #81bc0d;--hb-color-platform-xbox: #0f7c10;--hb-color-game-record-white-01: rgba(255, 255, 255, .01);--hb-color-game-record-black-01: rgba(0, 0, 0, .01);--hb-color-game-record-white-02: rgba(255, 255, 255, .02);--hb-color-game-record-black-02: rgba(0, 0, 0, .02);--hb-color-game-record-white-03: rgba(255, 255, 255, .03);--hb-color-game-record-black-03: rgba(0, 0, 0, .03);--hb-color-game-record-white-05: rgba(255, 255, 255, .05);--hb-color-game-record-black-05: rgba(0, 0, 0, .05);--hb-color-game-record-white-08: rgba(255, 255, 255, .08);--hb-color-game-record-black-08: rgba(0, 0, 0, .08);--hb-color-game-record-white-10: rgba(255, 255, 255, .1);--hb-color-game-record-black-10: rgba(0, 0, 0, .1);--hb-color-game-record-white-15: rgba(255, 255, 255, .15);--hb-color-game-record-black-15: rgba(0, 0, 0, .15);--hb-color-game-record-white-20: rgba(255, 255, 255, .2);--hb-color-game-record-black-20: rgba(0, 0, 0, .2);--hb-color-game-record-white-30: rgba(255, 255, 255, .3);--hb-color-game-record-black-30: rgba(0, 0, 0, .3);--hb-color-game-record-white-40: rgba(255, 255, 255, .4);--hb-color-game-record-black-40: rgba(0, 0, 0, .4);--hb-color-game-record-white-50: rgba(255, 255, 255, .5);--hb-color-game-record-black-50: rgba(0, 0, 0, .5);--hb-color-game-record-white-60: rgba(255, 255, 255, .6);--hb-color-game-record-black-60: rgba(0, 0, 0, .6);--hb-color-game-record-white-70: rgba(255, 255, 255, .7);--hb-color-game-record-black-70: rgba(0, 0, 0, .7);--hb-color-game-record-white-80: rgba(255, 255, 255, .8);--hb-color-game-record-black-80: rgba(0, 0, 0, .8);--hb-color-game-record-white-85: rgba(255, 255, 255, .85);--hb-color-game-record-black-85: rgba(0, 0, 0, .85);--hb-color-game-record-white-90: rgba(255, 255, 255, .9);--hb-color-game-record-black-90: rgba(0, 0, 0, .9);--hb-color-game-record-white-100: #ffffff;--hb-color-game-record-black-100: #000000;color-scheme:light}:root[data-hb-theme=dark]{--hb-color-icon-primary: #cccdce;--hb-color-icon-secondary: #9b9fa2;--hb-color-icon-tertiary: #858687;--hb-color-icon-disabled: #4f5459;--hb-color-icon-inverse: #101112;--hb-color-text-primary: #cccdce;--hb-color-text-secondary: #9b9fa2;--hb-color-text-tertiary: #858687;--hb-color-text-placeholder: #4f5459;--hb-color-text-inverse: #101112;--hb-color-border-default: #242628;--hb-color-border-muted: #2e3031;--hb-color-border-strong: #424547;--hb-color-border-section: #0b0c0e;--hb-color-border-inverse: #101112;--hb-color-bg-page: #101112;--hb-color-bg-surface: #151617;--hb-color-bg-subtle: #1e1f21;--hb-color-bg-muted: #242628;--hb-color-bg-raised: #2e3031;--hb-color-bg-chat: #1e1f21;--hb-color-bg-control-secondary: #373839;--hb-color-bg-chat-bubble: #1f2e4d;--hb-color-bg-toast: rgba(187, 191, 194, .8980392157);--hb-color-bg-popmask: rgba(21, 21, 21, .5019607843);--hb-color-action-link: #66b3ff;--hb-color-action-link-subtle: rgba(102, 179, 255, .1019607843);--hb-color-brand-primary: #006ef4;--hb-color-status-danger: #fa3c4b;--hb-color-status-success: #4cd964;--hb-color-game-price-coupon: #f67010;--hb-color-game-price-low: #32b846;--hb-color-game-price-new-low: #009015;--hb-color-platform-playstation: #0071ce;--hb-color-platform-steam: #234c75;--hb-color-platform-switch: #e70012;--hb-color-platform-windows: #81bc0d;--hb-color-platform-xbox: #0f7c10;--hb-color-game-record-white-01: rgba(0, 0, 0, .01);--hb-color-game-record-black-01: rgba(255, 255, 255, .01);--hb-color-game-record-white-02: rgba(0, 0, 0, .02);--hb-color-game-record-black-02: rgba(255, 255, 255, .02);--hb-color-game-record-white-03: rgba(0, 0, 0, .03);--hb-color-game-record-black-03: rgba(255, 255, 255, .03);--hb-color-game-record-white-05: rgba(0, 0, 0, .05);--hb-color-game-record-black-05: rgba(255, 255, 255, .05);--hb-color-game-record-white-08: rgba(0, 0, 0, .08);--hb-color-game-record-black-08: rgba(255, 255, 255, .08);--hb-color-game-record-white-10: rgba(0, 0, 0, .1);--hb-color-game-record-black-10: rgba(255, 255, 255, .1);--hb-color-game-record-white-15: rgba(0, 0, 0, .15);--hb-color-game-record-black-15: rgba(255, 255, 255, .15);--hb-color-game-record-white-20: rgba(0, 0, 0, .2);--hb-color-game-record-black-20: rgba(255, 255, 255, .2);--hb-color-game-record-white-30: rgba(0, 0, 0, .3);--hb-color-game-record-black-30: rgba(255, 255, 255, .3);--hb-color-game-record-white-40: rgba(0, 0, 0, .4);--hb-color-game-record-black-40: rgba(255, 255, 255, .4);--hb-color-game-record-white-50: rgba(0, 0, 0, .5);--hb-color-game-record-black-50: rgba(255, 255, 255, .5);--hb-color-game-record-white-60: rgba(0, 0, 0, .6);--hb-color-game-record-black-60: rgba(255, 255, 255, .6);--hb-color-game-record-white-70: rgba(0, 0, 0, .7);--hb-color-game-record-black-70: rgba(255, 255, 255, .7);--hb-color-game-record-white-80: rgba(0, 0, 0, .8);--hb-color-game-record-black-80: rgba(255, 255, 255, .8);--hb-color-game-record-white-85: rgba(0, 0, 0, .85);--hb-color-game-record-black-85: rgba(255, 255, 255, .85);--hb-color-game-record-white-90: rgba(0, 0, 0, .9);--hb-color-game-record-black-90: rgba(255, 255, 255, .9);--hb-color-game-record-white-100: #000000;--hb-color-game-record-black-100: #ffffff;color-scheme:dark}:root[data-hb-theme=auto]{--hb-color-icon-primary: #14191e;--hb-color-icon-secondary: #64696e;--hb-color-icon-tertiary: #8c9196;--hb-color-icon-disabled: #c8cdd2;--hb-color-icon-inverse: #ffffff;--hb-color-text-primary: #14191e;--hb-color-text-secondary: #64696e;--hb-color-text-tertiary: #8c9196;--hb-color-text-placeholder: #c8cdd2;--hb-color-text-inverse: #ffffff;--hb-color-border-default: #f3f4f5;--hb-color-border-muted: #f1f2f3;--hb-color-border-strong: #dadde0;--hb-color-border-section: #fafbfc;--hb-color-border-inverse: #ffffff;--hb-color-bg-page: #ffffff;--hb-color-bg-surface: #fafbfc;--hb-color-bg-subtle: #f7f8f9;--hb-color-bg-muted: #f3f4f5;--hb-color-bg-raised: #f1f2f3;--hb-color-bg-chat: #f1f2f3;--hb-color-bg-control-secondary: #e7e8e9;--hb-color-bg-chat-bubble: #c4e4fc;--hb-color-bg-toast: rgba(57, 61, 64, .8980392157);--hb-color-bg-popmask: rgba(0, 0, 0, .5019607843);--hb-color-action-link: #004b96;--hb-color-action-link-subtle: rgba(0, 75, 150, .1019607843);--hb-color-brand-primary: #006ef4;--hb-color-status-danger: #fa3c4b;--hb-color-status-success: #32b846;--hb-color-game-price-coupon: #f67010;--hb-color-game-price-low: #32b846;--hb-color-game-price-new-low: #009015;--hb-color-platform-playstation: #0071ce;--hb-color-platform-steam: #021930;--hb-color-platform-switch: #e70012;--hb-color-platform-windows: #81bc0d;--hb-color-platform-xbox: #0f7c10;--hb-color-game-record-white-01: rgba(255, 255, 255, .01);--hb-color-game-record-black-01: rgba(0, 0, 0, .01);--hb-color-game-record-white-02: rgba(255, 255, 255, .02);--hb-color-game-record-black-02: rgba(0, 0, 0, .02);--hb-color-game-record-white-03: rgba(255, 255, 255, .03);--hb-color-game-record-black-03: rgba(0, 0, 0, .03);--hb-color-game-record-white-05: rgba(255, 255, 255, .05);--hb-color-game-record-black-05: rgba(0, 0, 0, .05);--hb-color-game-record-white-08: rgba(255, 255, 255, .08);--hb-color-game-record-black-08: rgba(0, 0, 0, .08);--hb-color-game-record-white-10: rgba(255, 255, 255, .1);--hb-color-game-record-black-10: rgba(0, 0, 0, .1);--hb-color-game-record-white-15: rgba(255, 255, 255, .15);--hb-color-game-record-black-15: rgba(0, 0, 0, .15);--hb-color-game-record-white-20: rgba(255, 255, 255, .2);--hb-color-game-record-black-20: rgba(0, 0, 0, .2);--hb-color-game-record-white-30: rgba(255, 255, 255, .3);--hb-color-game-record-black-30: rgba(0, 0, 0, .3);--hb-color-game-record-white-40: rgba(255, 255, 255, .4);--hb-color-game-record-black-40: rgba(0, 0, 0, .4);--hb-color-game-record-white-50: rgba(255, 255, 255, .5);--hb-color-game-record-black-50: rgba(0, 0, 0, .5);--hb-color-game-record-white-60: rgba(255, 255, 255, .6);--hb-color-game-record-black-60: rgba(0, 0, 0, .6);--hb-color-game-record-white-70: rgba(255, 255, 255, .7);--hb-color-game-record-black-70: rgba(0, 0, 0, .7);--hb-color-game-record-white-80: rgba(255, 255, 255, .8);--hb-color-game-record-black-80: rgba(0, 0, 0, .8);--hb-color-game-record-white-85: rgba(255, 255, 255, .85);--hb-color-game-record-black-85: rgba(0, 0, 0, .85);--hb-color-game-record-white-90: rgba(255, 255, 255, .9);--hb-color-game-record-black-90: rgba(0, 0, 0, .9);--hb-color-game-record-white-100: #ffffff;--hb-color-game-record-black-100: #000000;color-scheme:light}@media(prefers-color-scheme:dark){:root:not([data-hb-theme]){--hb-color-icon-primary: #cccdce;--hb-color-icon-secondary: #9b9fa2;--hb-color-icon-tertiary: #858687;--hb-color-icon-disabled: #4f5459;--hb-color-icon-inverse: #101112;--hb-color-text-primary: #cccdce;--hb-color-text-secondary: #9b9fa2;--hb-color-text-tertiary: #858687;--hb-color-text-placeholder: #4f5459;--hb-color-text-inverse: #101112;--hb-color-border-default: #242628;--hb-color-border-muted: #2e3031;--hb-color-border-strong: #424547;--hb-color-border-section: #0b0c0e;--hb-color-border-inverse: #101112;--hb-color-bg-page: #101112;--hb-color-bg-surface: #151617;--hb-color-bg-subtle: #1e1f21;--hb-color-bg-muted: #242628;--hb-color-bg-raised: #2e3031;--hb-color-bg-chat: #1e1f21;--hb-color-bg-control-secondary: #373839;--hb-color-bg-chat-bubble: #1f2e4d;--hb-color-bg-toast: rgba(187, 191, 194, .8980392157);--hb-color-bg-popmask: rgba(21, 21, 21, .5019607843);--hb-color-action-link: #66b3ff;--hb-color-action-link-subtle: rgba(102, 179, 255, .1019607843);--hb-color-brand-primary: #006ef4;--hb-color-status-danger: #fa3c4b;--hb-color-status-success: #4cd964;--hb-color-game-price-coupon: #f67010;--hb-color-game-price-low: #32b846;--hb-color-game-price-new-low: #009015;--hb-color-platform-playstation: #0071ce;--hb-color-platform-steam: #234c75;--hb-color-platform-switch: #e70012;--hb-color-platform-windows: #81bc0d;--hb-color-platform-xbox: #0f7c10;--hb-color-game-record-white-01: rgba(0, 0, 0, .01);--hb-color-game-record-black-01: rgba(255, 255, 255, .01);--hb-color-game-record-white-02: rgba(0, 0, 0, .02);--hb-color-game-record-black-02: rgba(255, 255, 255, .02);--hb-color-game-record-white-03: rgba(0, 0, 0, .03);--hb-color-game-record-black-03: rgba(255, 255, 255, .03);--hb-color-game-record-white-05: rgba(0, 0, 0, .05);--hb-color-game-record-black-05: rgba(255, 255, 255, .05);--hb-color-game-record-white-08: rgba(0, 0, 0, .08);--hb-color-game-record-black-08: rgba(255, 255, 255, .08);--hb-color-game-record-white-10: rgba(0, 0, 0, .1);--hb-color-game-record-black-10: rgba(255, 255, 255, .1);--hb-color-game-record-white-15: rgba(0, 0, 0, .15);--hb-color-game-record-black-15: rgba(255, 255, 255, .15);--hb-color-game-record-white-20: rgba(0, 0, 0, .2);--hb-color-game-record-black-20: rgba(255, 255, 255, .2);--hb-color-game-record-white-30: rgba(0, 0, 0, .3);--hb-color-game-record-black-30: rgba(255, 255, 255, .3);--hb-color-game-record-white-40: rgba(0, 0, 0, .4);--hb-color-game-record-black-40: rgba(255, 255, 255, .4);--hb-color-game-record-white-50: rgba(0, 0, 0, .5);--hb-color-game-record-black-50: rgba(255, 255, 255, .5);--hb-color-game-record-white-60: rgba(0, 0, 0, .6);--hb-color-game-record-black-60: rgba(255, 255, 255, .6);--hb-color-game-record-white-70: rgba(0, 0, 0, .7);--hb-color-game-record-black-70: rgba(255, 255, 255, .7);--hb-color-game-record-white-80: rgba(0, 0, 0, .8);--hb-color-game-record-black-80: rgba(255, 255, 255, .8);--hb-color-game-record-white-85: rgba(0, 0, 0, .85);--hb-color-game-record-black-85: rgba(255, 255, 255, .85);--hb-color-game-record-white-90: rgba(0, 0, 0, .9);--hb-color-game-record-black-90: rgba(255, 255, 255, .9);--hb-color-game-record-white-100: #000000;--hb-color-game-record-black-100: #ffffff;color-scheme:dark}:root[data-hb-theme=auto]{--hb-color-icon-primary: #cccdce;--hb-color-icon-secondary: #9b9fa2;--hb-color-icon-tertiary: #858687;--hb-color-icon-disabled: #4f5459;--hb-color-icon-inverse: #101112;--hb-color-text-primary: #cccdce;--hb-color-text-secondary: #9b9fa2;--hb-color-text-tertiary: #858687;--hb-color-text-placeholder: #4f5459;--hb-color-text-inverse: #101112;--hb-color-border-default: #242628;--hb-color-border-muted: #2e3031;--hb-color-border-strong: #424547;--hb-color-border-section: #0b0c0e;--hb-color-border-inverse: #101112;--hb-color-bg-page: #101112;--hb-color-bg-surface: #151617;--hb-color-bg-subtle: #1e1f21;--hb-color-bg-muted: #242628;--hb-color-bg-raised: #2e3031;--hb-color-bg-chat: #1e1f21;--hb-color-bg-control-secondary: #373839;--hb-color-bg-chat-bubble: #1f2e4d;--hb-color-bg-toast: rgba(187, 191, 194, .8980392157);--hb-color-bg-popmask: rgba(21, 21, 21, .5019607843);--hb-color-action-link: #66b3ff;--hb-color-action-link-subtle: rgba(102, 179, 255, .1019607843);--hb-color-brand-primary: #006ef4;--hb-color-status-danger: #fa3c4b;--hb-color-status-success: #4cd964;--hb-color-game-price-coupon: #f67010;--hb-color-game-price-low: #32b846;--hb-color-game-price-new-low: #009015;--hb-color-platform-playstation: #0071ce;--hb-color-platform-steam: #234c75;--hb-color-platform-switch: #e70012;--hb-color-platform-windows: #81bc0d;--hb-color-platform-xbox: #0f7c10;--hb-color-game-record-white-01: rgba(0, 0, 0, .01);--hb-color-game-record-black-01: rgba(255, 255, 255, .01);--hb-color-game-record-white-02: rgba(0, 0, 0, .02);--hb-color-game-record-black-02: rgba(255, 255, 255, .02);--hb-color-game-record-white-03: rgba(0, 0, 0, .03);--hb-color-game-record-black-03: rgba(255, 255, 255, .03);--hb-color-game-record-white-05: rgba(0, 0, 0, .05);--hb-color-game-record-black-05: rgba(255, 255, 255, .05);--hb-color-game-record-white-08: rgba(0, 0, 0, .08);--hb-color-game-record-black-08: rgba(255, 255, 255, .08);--hb-color-game-record-white-10: rgba(0, 0, 0, .1);--hb-color-game-record-black-10: rgba(255, 255, 255, .1);--hb-color-game-record-white-15: rgba(0, 0, 0, .15);--hb-color-game-record-black-15: rgba(255, 255, 255, .15);--hb-color-game-record-white-20: rgba(0, 0, 0, .2);--hb-color-game-record-black-20: rgba(255, 255, 255, .2);--hb-color-game-record-white-30: rgba(0, 0, 0, .3);--hb-color-game-record-black-30: rgba(255, 255, 255, .3);--hb-color-game-record-white-40: rgba(0, 0, 0, .4);--hb-color-game-record-black-40: rgba(255, 255, 255, .4);--hb-color-game-record-white-50: rgba(0, 0, 0, .5);--hb-color-game-record-black-50: rgba(255, 255, 255, .5);--hb-color-game-record-white-60: rgba(0, 0, 0, .6);--hb-color-game-record-black-60: rgba(255, 255, 255, .6);--hb-color-game-record-white-70: rgba(0, 0, 0, .7);--hb-color-game-record-black-70: rgba(255, 255, 255, .7);--hb-color-game-record-white-80: rgba(0, 0, 0, .8);--hb-color-game-record-black-80: rgba(255, 255, 255, .8);--hb-color-game-record-white-85: rgba(0, 0, 0, .85);--hb-color-game-record-black-85: rgba(255, 255, 255, .85);--hb-color-game-record-white-90: rgba(0, 0, 0, .9);--hb-color-game-record-black-90: rgba(255, 255, 255, .9);--hb-color-game-record-white-100: #000000;--hb-color-game-record-black-100: #ffffff;color-scheme:dark}}*,*:before,*:after{box-sizing:border-box}html{min-height:100%;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;color:var(--hb-color-text-primary, #14191e);background:var(--hb-page-background, var(--hb-color-bg-page, #ffffff));text-size-adjust:100%;-webkit-text-size-adjust:100%}body{min-height:100%;margin:0;color:inherit;background-color:inherit}button,input,select,textarea{font:inherit;color:inherit}img,picture,video,canvas{display:block;max-width:100%}[hidden]{display:none!important}*{box-sizing:border-box}html,body,#app{width:100%;height:100%;margin:0}body{overflow:hidden;background:var(--hb-color-bg-page);color:var(--hb-color-text-primary)}button,input,select{font:inherit;letter-spacing:0}button{color:inherit}.workbench{display:grid;grid-template-rows:52px auto minmax(0,1fr) 28px;height:100%;background:#f3f4f6}.workbench__header{z-index:20;display:flex;align-items:center;justify-content:space-between;padding:0 20px;border:1px solid var(--hb-color-border-muted);background:var(--hb-color-bg-surface)}.workbench__header:before{position:absolute;top:0;right:0;left:0;height:2px;background:#006ef4;content:""}.brand{display:flex;align-items:center;min-width:0;gap:16px}.brand__logo{display:block;width:54px;height:16px;flex:0 0 54px}.brand__title{color:var(--hb-color-text-primary);white-space:nowrap;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:14px;line-height:normal;letter-spacing:0px}.workbench__header-actions{display:flex;align-items:center;gap:8px}.desktop-launch{position:relative}.workbench__identity{position:relative;display:flex;align-items:center;gap:10px}.toolbar-asset{display:block;flex:0 0 auto;object-fit:contain;pointer-events:none}.toolbar-asset--12{width:12px;height:12px}.toolbar-asset--16{width:16px;height:16px}.toolbar-asset--18{width:18px;height:18px}.workbench__main{min-width:0;min-height:0}.splitpanes{height:100%}.splitpanes__pane{min-width:0;min-height:0;overflow:hidden}.splitpanes__splitter{position:relative;width:5px;flex:0 0 5px;margin:0 -2px;z-index:8;background:transparent;cursor:col-resize}.splitpanes__splitter:after{position:absolute;top:0;bottom:0;left:2px;width:1px;background:var(--hb-color-border-muted);content:"";transition:background .15s}.splitpanes__splitter:hover:after,.splitpanes__splitter:focus:after{background:var(--hb-color-brand-primary)}.diagnostics{display:grid;height:100%;grid-template-rows:60px auto 44px 48px minmax(0,1fr);min-width:0;min-height:0;background:#fff}.mini-program-summary{display:flex;height:60px;align-items:center;gap:10px;min-width:0;padding:0 16px}.mini-program-summary__icon{display:grid;width:36px;height:36px;flex:0 0 auto;overflow:hidden;place-items:center;border:0;border-radius:10px;background:#e5f2ff;color:#006ef4}.mini-program-summary__icon img{width:100%;height:100%;object-fit:cover}.mini-program-summary__fallback{font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:14px;line-height:normal;letter-spacing:0px}.mini-program-summary__copy{display:grid;min-width:0;gap:4px}.mini-program-summary__copy strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:14px;line-height:normal;letter-spacing:0px}.mini-program-summary__copy span{overflow:hidden;color:var(--hb-color-text-secondary);text-overflow:ellipsis;white-space:nowrap;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:11px;line-height:16px;letter-spacing:0px}.diagnostics__tabs{display:flex;height:44px;align-items:center;padding:6px 12px;gap:4px}.diagnostics__tabs button{position:relative;display:flex;height:28px;align-items:center;justify-content:center;padding:4px 12px;border:0;border-radius:8px;color:#1f2126c7;background:var(--hb-color-bg-muted);cursor:pointer;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:11px;line-height:16px;letter-spacing:0px}.diagnostics__tabs button.active{color:#fff;background:linear-gradient(23deg,#464b50 .9%,#14191e 100.9%)}.diagnostics__tabs button.diagnostics__tab--logs{width:46px}.diagnostics__tabs button.diagnostics__tab--storage{width:56px}.diagnostics__tabs button.diagnostics__tab--problems{width:46px}.diagnostics__count{position:absolute;top:-6px;right:-8px;min-width:16px;height:16px;padding:0 4px;border-radius:8px;color:#fff;background:var(--hb-color-status-danger);text-align:center;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:10px;line-height:13px;letter-spacing:0px}.diagnostics__toolbar{display:flex;height:48px;align-items:center;justify-content:space-between;padding:0 12px;border-bottom:1px solid var(--hb-color-border-muted);gap:8px}.search-field{display:flex;width:auto;height:32px;flex:1 1 auto;align-items:center;gap:4px;padding:4px 8px;border:1px solid var(--hb-color-border-muted);border-radius:8px;color:var(--hb-color-text-placeholder);background:var(--hb-color-bg-page)}.search-field:focus-within{border-color:var(--hb-color-border-strong);background:var(--hb-color-bg-surface)}.search-field input{width:100%;min-width:0;border:0;outline:0;color:var(--hb-color-text-primary);background:transparent;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:11px;line-height:16px;letter-spacing:0px}.diagnostics__toolbar-actions{display:flex;flex:0 0 auto;margin-left:auto;align-items:center;gap:8px}.diagnostics__content{width:100%;min-height:0;overflow:hidden}.log-list,.storage-list,.problem-list{height:100%;padding:8px;overflow:auto;overscroll-behavior:contain}.storage-row{width:100%;min-width:0;max-width:100%;margin-bottom:2px;border:1px solid var(--hb-color-border-muted);border-radius:8px;background:var(--hb-color-bg-page)}.storage-row summary{display:flex;height:38px;min-height:38px;align-items:center;justify-content:space-between;padding:4px 8px 4px 12px;list-style:none;cursor:pointer}.storage-row summary::-webkit-details-marker{display:none}.storage-row summary>span{display:grid;min-width:0;flex:1;grid-template-columns:minmax(96px,35%) minmax(0,1fr);align-items:center;gap:8px}.storage-row strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:11px;line-height:16px;letter-spacing:0px}.storage-row small{overflow:hidden;color:var(--hb-color-text-secondary);text-align:right;text-overflow:ellipsis;white-space:nowrap;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:10px;line-height:13px;letter-spacing:0px}.storage-row code{display:block;max-height:160px;overflow:auto;padding:8px 12px;border-top:1px solid var(--hb-color-border-muted);color:var(--hb-color-text-secondary);background:var(--hb-color-bg-subtle);white-space:pre-wrap;overflow-wrap:anywhere;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:10px;line-height:13px;letter-spacing:0px}.problem-row{display:grid;width:100%;min-width:0;max-width:100%;grid-template-columns:3px minmax(0,1fr) 32px;min-height:40px;align-items:center;margin-bottom:2px;padding:0 8px 0 12px;border:1px solid var(--hb-color-border-muted);border-radius:8px;color:var(--hb-color-text-primary);gap:10px}.problem-row__indicator{width:3px;height:24px;border-radius:2px;background:var(--hb-color-status-danger)}.problem-row__content{display:grid;min-width:0;grid-template-columns:minmax(96px,35%) minmax(0,1fr);align-items:center;gap:8px}.problem-row__content strong,.problem-row__content small{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.problem-row__content strong{font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:11px;line-height:16px;letter-spacing:0px}.problem-row__content small{color:var(--hb-color-text-secondary);text-align:right;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:10px;line-height:13px;letter-spacing:0px}.empty-state{display:grid;height:180px;margin:0;place-items:center;color:var(--hb-color-text-tertiary);font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:12px;line-height:16px;letter-spacing:0px}.empty-state--error{color:var(--hb-color-status-danger)}.csp-violations{padding:10px 12px;color:var(--hb-color-status-danger);background:#eb4b4b0f;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:11px;line-height:16px;letter-spacing:0px}.csp-violations[hidden]{display:none}.device-stage{position:relative;display:grid;width:100%;height:100%;min-width:0;min-height:0;place-items:center;overflow:hidden;padding:0;background:var(--hb-color-bg-muted)}.device-stage__toolbar{position:absolute;top:28px;left:var(--device-toolbar-left);z-index:10;display:flex;align-items:center;gap:12px;transform:none}.device-stage--compact .device-stage__toolbar{top:12px;left:50%;transform:translate(-50%)}.device-select{display:grid;grid-template-columns:auto minmax(0,1fr) auto;width:220px;height:32px;align-items:center;padding:0 6px 0 8px;border:1px solid rgba(255,255,255,.76);border-radius:14px;gap:3px;background:#ffffffad;box-shadow:0 7px 24px #1f23291f,inset 0 0 0 .5px #ffffffdb;-webkit-backdrop-filter:blur(18px) saturate(1.35);backdrop-filter:blur(18px) saturate(1.35);font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:12px;line-height:16px;letter-spacing:0px}.device-select__prefix{color:var(--hb-color-text-secondary);white-space:nowrap;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:11px;line-height:16px;letter-spacing:0px}.device-select>span:nth-child(2){min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--hb-color-text-primary);font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:11px;line-height:16px;letter-spacing:0px}.device-presentation{position:relative;flex:none}.device-shell{position:absolute;top:0;left:0;transform:scale(var(--device-scale));transform-origin:top left}.device-screen{position:absolute;z-index:1;display:grid;grid-template-rows:minmax(0,1fr);overflow:hidden;background:#fff}.device-frame{position:absolute;inset:0;z-index:3;display:block;width:var(--device-frame-asset-width);height:var(--device-frame-asset-height);transform:scale(var(--device-frame-scale-x),var(--device-frame-scale-y));transform-origin:top left;pointer-events:none}.mini-program-capsule{position:absolute;top:var(--mini-program-actions-top);right:var(--mini-program-actions-right);z-index:4;display:block;width:87px;height:32px;pointer-events:none}.mini-program-capsule--light{filter:invert(1)}.device-system-navigation{position:absolute;left:50%;z-index:9;display:block;border-radius:999px;transform:translate(-50%);pointer-events:none}.device-system-navigation--ios{bottom:8px;width:157px;height:5px;background:#0d0d0e}.device-system-navigation--android{bottom:10px;width:108px;height:4px;background:#222227}.device-content{position:relative;width:100%;min-width:0;min-height:0;overflow:hidden}.device-content iframe{display:block;width:100%;min-width:0;max-width:none;height:100%;border:0;background:#fff}.browser-mock-preview{display:flex;height:100%;flex-direction:column;align-items:center;justify-content:center;padding-bottom:120px;color:var(--hb-color-text-primary);gap:7px}.browser-mock-preview__icon{display:grid;width:38px;height:38px;place-items:center;border-radius:7px;color:#fff;background:#006ef4;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:14px;line-height:normal;letter-spacing:0px}.browser-mock-preview strong{font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:13px;line-height:17px;letter-spacing:0px}.browser-mock-preview small{color:var(--hb-color-text-secondary);font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:10px;line-height:13px;letter-spacing:0px}.placeholder,.error{display:grid;height:100%;place-items:center;padding:24px;color:var(--hb-color-text-tertiary);text-align:center;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:13px;line-height:17px;letter-spacing:0px}.error{color:var(--hb-color-status-danger)}.host-overlay-layer{position:absolute;inset:0;z-index:8;overflow:hidden;pointer-events:none}.host-overlay-layer>*{pointer-events:auto}.host-overlay-layer .hb-v2-toast__wrapper{position:absolute}.host-overlay-layer>.hb-v2-toast__wrapper{pointer-events:none}.host-feedback-loading-mask{position:absolute;inset:0;z-index:50;background:transparent;pointer-events:auto;touch-action:none}.hb-sdk-auth-dialog{position:absolute;inset:0;display:grid;place-items:center;padding:20px;background:#14161a6b}.hb-sdk-auth-dialog__panel{width:min(320px,100%);padding:18px;border:1px solid rgba(255,255,255,.72);border-radius:12px;background:#fffffff5;box-shadow:0 18px 42px #0003}.hb-sdk-auth-dialog__panel h2{margin:0 0 7px;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:16px;line-height:normal;letter-spacing:0px}.hb-sdk-auth-dialog__app,.hb-sdk-auth-dialog__profile{margin:0 0 10px;color:var(--hb-color-text-secondary);font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:12px;line-height:16px;letter-spacing:0px}.hb-sdk-auth-dialog__scopes{margin:0 0 14px;padding-left:18px;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:12px;line-height:16px;letter-spacing:0px}.hb-sdk-auth-dialog__actions{display:flex;justify-content:flex-end;gap:8px}.hb-sdk-auth-dialog__actions button{height:32px;padding:0 12px;border:1px solid var(--hb-color-border-muted);border-radius:7px;background:#fff;cursor:pointer;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:12px;line-height:16px;letter-spacing:0px}.hb-sdk-auth-dialog__actions .primary{border-color:#f1c232;color:#1f1f1f;background:#f7cb45}.qr-popover__image{width:180px;height:180px;justify-self:center;border-radius:6px;background:var(--hb-color-bg-subtle)}.qr-popover__field{display:grid;grid-template-columns:auto minmax(0,1fr);align-items:center;color:var(--hb-color-text-tertiary);gap:8px;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:11px;line-height:16px;letter-spacing:0px}.qr-popover__field select{min-width:0;height:28px;border:1px solid var(--hb-color-border-muted);border-radius:6px;padding:0 7px;background:#fff;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:11px;line-height:16px;letter-spacing:0px}.workbench--chrome-hidden .workbench__header,.workbench--chrome-hidden .workbench__permission-status,.workbench--chrome-hidden .diagnostics,.workbench--chrome-hidden .device-stage__toolbar{display:none}.workbench--chrome-hidden{grid-template-rows:minmax(0,1fr)}.workbench--chrome-hidden .splitpanes__pane:first-child,.workbench--chrome-hidden .splitpanes__splitter,.workbench--chrome-hidden .activity-bar{display:none}.workbench--chrome-hidden .splitpanes__pane:last-child{width:100%!important}html[data-screenshot-chrome-hidden=true] .workbench__header,html[data-screenshot-chrome-hidden=true] .workbench__permission-status,html[data-screenshot-chrome-hidden=true] .diagnostics,html[data-screenshot-chrome-hidden=true] .device-stage__toolbar{display:none}html[data-screenshot-chrome-hidden=true] .workbench{grid-template-rows:minmax(0,1fr)}html[data-screenshot-chrome-hidden=true] .splitpanes__pane:first-child,html[data-screenshot-chrome-hidden=true] .splitpanes__splitter,html[data-screenshot-chrome-hidden=true] .activity-bar{display:none}html[data-screenshot-chrome-hidden=true] .splitpanes__pane:last-child{width:100%!important}.activity-bar{z-index:15;display:flex;align-items:center;justify-content:space-between;padding:0 12px;border-top:1px solid var(--hb-color-border-muted);background:var(--hb-color-bg-surface);color:var(--hb-color-text-secondary);font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:11px;line-height:16px;letter-spacing:0px}.activity-bar>div{display:flex;align-items:center;gap:12px}.activity-account,.activity-status{display:flex;align-items:center;color:var(--hb-color-text-primary);gap:12px}.activity-status{font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:11px;line-height:16px;letter-spacing:0px}.activity-status i{width:6px;height:6px;border-radius:50%;background:var(--hb-color-text-tertiary)}.activity-status .activity-status--ready{background:var(--hb-color-status-success)}.activity-status .activity-status--loading{background:#d69e16}.activity-status .activity-status--error{background:var(--hb-color-status-danger)}.toolbar-badge{position:absolute;top:-4px;right:-4px;min-width:15px;height:15px;padding:0 3px;border-radius:8px;color:#fff;background:var(--hb-color-status-danger);text-align:center;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:500;font-size:10px;line-height:13px;letter-spacing:0px}.device-select-menu{z-index:40;min-width:230px;overflow:hidden;padding:4px;border:1px solid var(--hb-color-border-muted);border-radius:9px;background:#fff;box-shadow:0 14px 36px #1f232929}.device-select-item{display:grid;min-height:34px;grid-template-columns:minmax(0,1fr) auto;align-items:center;padding:0 9px;border-radius:6px;outline:none;cursor:pointer;font-family:PingFang SC,Noto Sans CJK SC,xiaomi,BlinkMacSystemFont,Microsoft YaHei,sans-serif;font-weight:400;font-size:11px;line-height:16px;letter-spacing:0px}.device-select-item[data-highlighted]{background:var(--hb-color-bg-subtle)}@media(max-width:780px){.device-stage{padding-right:12px;padding-left:12px}}
|
|
@@ -5,9 +5,9 @@
|
|
|
5
5
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
6
|
<meta name="theme-color" content="#f4f5f7" />
|
|
7
7
|
<title>小程序工坊调试台</title>
|
|
8
|
-
<script type="module" crossorigin src="/assets/index-
|
|
9
|
-
<link rel="modulepreload" crossorigin href="/assets/desktop-app-launch-
|
|
10
|
-
<link rel="stylesheet" crossorigin href="/assets/index-
|
|
8
|
+
<script type="module" crossorigin src="/assets/index-8N4og21f.js"></script>
|
|
9
|
+
<link rel="modulepreload" crossorigin href="/assets/desktop-app-launch-BbRQb08Y.js">
|
|
10
|
+
<link rel="stylesheet" crossorigin href="/assets/index-BrXEMo2-.css">
|
|
11
11
|
</head>
|
|
12
12
|
<body>
|
|
13
13
|
<div id="app"></div>
|
package/dist/index.cjs.js
CHANGED
|
@@ -748,7 +748,7 @@ const COMPANION_SHOW_NOTIFICATION_METHOD = 'companion.showNotification';
|
|
|
748
748
|
* @see [parseMiniProgramRuntimePermissions](/reference/symbols/protocol/functions/parseMiniProgramRuntimePermissions) Runtime 权限快照解析器。
|
|
749
749
|
*/
|
|
750
750
|
function isMiniProgramBridgeMessage(value) {
|
|
751
|
-
if (!isRecord$
|
|
751
|
+
if (!isRecord$3(value))
|
|
752
752
|
return false;
|
|
753
753
|
if (value.namespace !== MINI_PROGRAM_MESSAGE_NAMESPACE || (value.version !== 1 && value.version !== 2) || !isNonEmptyString$1(value.nonce)) {
|
|
754
754
|
return false;
|
|
@@ -898,7 +898,7 @@ function isMiniProgramRelativePath(value) {
|
|
|
898
898
|
* @see [DirectoryHandle](/reference/symbols/root/interfaces/DirectoryHandle) 可作为 derived path root 的目录代理。
|
|
899
899
|
*/
|
|
900
900
|
function isMiniProgramPathRootRef(value) {
|
|
901
|
-
if (!isRecord$
|
|
901
|
+
if (!isRecord$3(value))
|
|
902
902
|
return false;
|
|
903
903
|
if (value.kind === 'sandbox')
|
|
904
904
|
return hasOnlyKeys(value, ['kind']);
|
|
@@ -964,7 +964,7 @@ function isMiniProgramPathRootRef(value) {
|
|
|
964
964
|
* @see [FileHandle](/reference/symbols/root/interfaces/FileHandle) 使用文件引用的公开 I/O 代理。
|
|
965
965
|
*/
|
|
966
966
|
function isMiniProgramFileRef(value) {
|
|
967
|
-
if (!isRecord$
|
|
967
|
+
if (!isRecord$3(value) || value.kind !== 'file')
|
|
968
968
|
return false;
|
|
969
969
|
if (isNonEmptyString$1(value.handleId)) {
|
|
970
970
|
return hasOnlyKeys(value, ['kind', 'handleId']);
|
|
@@ -1031,7 +1031,7 @@ function isMiniProgramFileRef(value) {
|
|
|
1031
1031
|
* @see [DirectoryHandle](/reference/symbols/root/interfaces/DirectoryHandle) 使用目录引用的公开路径操作代理。
|
|
1032
1032
|
*/
|
|
1033
1033
|
function isMiniProgramDirectoryRef(value) {
|
|
1034
|
-
if (!isRecord$
|
|
1034
|
+
if (!isRecord$3(value) || value.kind !== 'directory')
|
|
1035
1035
|
return false;
|
|
1036
1036
|
if (isNonEmptyString$1(value.handleId)) {
|
|
1037
1037
|
return hasOnlyKeys(value, ['kind', 'handleId']);
|
|
@@ -1150,7 +1150,7 @@ function isMiniProgramByteArray(value) {
|
|
|
1150
1150
|
* @see [FileHandle](/reference/symbols/root/interfaces/FileHandle) 提供 `stat()` 的当前 session 文件代理。
|
|
1151
1151
|
*/
|
|
1152
1152
|
function isMiniProgramFileStat(value) {
|
|
1153
|
-
return (isRecord$
|
|
1153
|
+
return (isRecord$3(value) &&
|
|
1154
1154
|
value.kind === 'file' &&
|
|
1155
1155
|
isNonNegativeSafeInteger(value.size) &&
|
|
1156
1156
|
(value.modifiedAt === undefined || isNonNegativeFiniteNumber(value.modifiedAt)) &&
|
|
@@ -1210,7 +1210,7 @@ function isMiniProgramFileStat(value) {
|
|
|
1210
1210
|
* @see [isMiniProgramBridgeMessage](/reference/symbols/protocol/functions/isMiniProgramBridgeMessage) operation progress envelope 的最低校验。
|
|
1211
1211
|
*/
|
|
1212
1212
|
function isMiniProgramDownloadProgressPayload(value) {
|
|
1213
|
-
if (!isRecord$
|
|
1213
|
+
if (!isRecord$3(value) ||
|
|
1214
1214
|
!isNonNegativeSafeInteger(value.loaded) ||
|
|
1215
1215
|
typeof value.lengthComputable !== 'boolean' ||
|
|
1216
1216
|
!hasOnlyKeys(value, ['loaded', 'total', 'lengthComputable'])) {
|
|
@@ -1221,7 +1221,7 @@ function isMiniProgramDownloadProgressPayload(value) {
|
|
|
1221
1221
|
return isNonNegativeSafeInteger(value.total) && value.loaded <= value.total;
|
|
1222
1222
|
}
|
|
1223
1223
|
function isMiniProgramCompanionPrepareProgress(value) {
|
|
1224
|
-
if (!isRecord$
|
|
1224
|
+
if (!isRecord$3(value))
|
|
1225
1225
|
return false;
|
|
1226
1226
|
if (value.phase === 'downloading') {
|
|
1227
1227
|
return (isNonNegativeSafeInteger(value.loaded) &&
|
|
@@ -1239,10 +1239,10 @@ function isMiniProgramOperationProgressPayload(value) {
|
|
|
1239
1239
|
return isMiniProgramDownloadProgressPayload(value) || isMiniProgramCompanionPrepareProgress(value);
|
|
1240
1240
|
}
|
|
1241
1241
|
function isSDKHandshakePayload(value) {
|
|
1242
|
-
return isRecord$
|
|
1242
|
+
return isRecord$3(value) && isNonEmptyString$1(value.href) && typeof value.userAgent === 'string' && isNonEmptyString$1(value.sdkVersion);
|
|
1243
1243
|
}
|
|
1244
1244
|
function isBridgeError(value) {
|
|
1245
|
-
return isRecord$
|
|
1245
|
+
return isRecord$3(value) && isNonEmptyString$1(value.code) && typeof value.message === 'string';
|
|
1246
1246
|
}
|
|
1247
1247
|
function isNonNegativeSafeInteger(value) {
|
|
1248
1248
|
return typeof value === 'number' && Number.isSafeInteger(value) && value >= 0;
|
|
@@ -1257,15 +1257,10 @@ function hasOnlyKeys(value, allowedKeys) {
|
|
|
1257
1257
|
const allowed = new Set(allowedKeys);
|
|
1258
1258
|
return Object.keys(value).every((key) => allowed.has(key));
|
|
1259
1259
|
}
|
|
1260
|
-
function isRecord$
|
|
1260
|
+
function isRecord$3(value) {
|
|
1261
1261
|
return typeof value === 'object' && value !== null && !Array.isArray(value);
|
|
1262
1262
|
}
|
|
1263
1263
|
|
|
1264
|
-
/** 当前用户信息与登录能力支持的完整 scope 目录(canonical 顺序)。 */
|
|
1265
|
-
const USER_INFO_AUTHORIZATION_SCOPES = ['identity', 'profile', 'steam_account'];
|
|
1266
|
-
/** Companion alias 的跨构建、Runtime 与 Host 规范。 */
|
|
1267
|
-
const COMPANION_ALIAS_PATTERN = /^[a-z][a-z0-9-]{0,31}$/;
|
|
1268
|
-
|
|
1269
1264
|
const MINI_PROGRAM_PERMISSION_KEYS = [
|
|
1270
1265
|
'userInfo',
|
|
1271
1266
|
'steamLibrary',
|
|
@@ -1281,6 +1276,11 @@ new Set(MINI_PROGRAM_PERMISSION_KEYS);
|
|
|
1281
1276
|
|
|
1282
1277
|
new Set(MINI_PROGRAM_PERMISSION_KEYS);
|
|
1283
1278
|
|
|
1279
|
+
/** 当前用户信息与登录能力支持的完整 scope 目录(canonical 顺序)。 */
|
|
1280
|
+
const USER_INFO_AUTHORIZATION_SCOPES = ['identity', 'profile', 'steam_account'];
|
|
1281
|
+
/** Companion alias 的跨构建、Runtime 与 Host 规范。 */
|
|
1282
|
+
const COMPANION_ALIAS_PATTERN = /^[a-z][a-z0-9-]{0,31}$/;
|
|
1283
|
+
|
|
1284
1284
|
/** 获取浏览器全局 window。 */
|
|
1285
1285
|
function getGlobalWindow() {
|
|
1286
1286
|
return typeof window === 'undefined' ? undefined : window;
|
|
@@ -1342,7 +1342,7 @@ function createMessageId() {
|
|
|
1342
1342
|
/** 构建时替换为当前发布包的实际版本。 */
|
|
1343
1343
|
const HB_SDK_VERSION = typeof undefined === 'string'
|
|
1344
1344
|
? undefined
|
|
1345
|
-
: '0.8.3-alpha.
|
|
1345
|
+
: '0.8.3-alpha.5';
|
|
1346
1346
|
|
|
1347
1347
|
const RUNTIME_MODES = new Set(['production', 'preview', 'development', 'unknown']);
|
|
1348
1348
|
const OPERATING_SYSTEM_NAMES = new Set(['android', 'ios', 'ohos', 'windows', 'macos', 'linux', 'unknown']);
|
package/dist/index.esm.js
CHANGED
|
@@ -744,7 +744,7 @@ const COMPANION_SHOW_NOTIFICATION_METHOD = 'companion.showNotification';
|
|
|
744
744
|
* @see [parseMiniProgramRuntimePermissions](/reference/symbols/protocol/functions/parseMiniProgramRuntimePermissions) Runtime 权限快照解析器。
|
|
745
745
|
*/
|
|
746
746
|
function isMiniProgramBridgeMessage(value) {
|
|
747
|
-
if (!isRecord$
|
|
747
|
+
if (!isRecord$3(value))
|
|
748
748
|
return false;
|
|
749
749
|
if (value.namespace !== MINI_PROGRAM_MESSAGE_NAMESPACE || (value.version !== 1 && value.version !== 2) || !isNonEmptyString$1(value.nonce)) {
|
|
750
750
|
return false;
|
|
@@ -894,7 +894,7 @@ function isMiniProgramRelativePath(value) {
|
|
|
894
894
|
* @see [DirectoryHandle](/reference/symbols/root/interfaces/DirectoryHandle) 可作为 derived path root 的目录代理。
|
|
895
895
|
*/
|
|
896
896
|
function isMiniProgramPathRootRef(value) {
|
|
897
|
-
if (!isRecord$
|
|
897
|
+
if (!isRecord$3(value))
|
|
898
898
|
return false;
|
|
899
899
|
if (value.kind === 'sandbox')
|
|
900
900
|
return hasOnlyKeys(value, ['kind']);
|
|
@@ -960,7 +960,7 @@ function isMiniProgramPathRootRef(value) {
|
|
|
960
960
|
* @see [FileHandle](/reference/symbols/root/interfaces/FileHandle) 使用文件引用的公开 I/O 代理。
|
|
961
961
|
*/
|
|
962
962
|
function isMiniProgramFileRef(value) {
|
|
963
|
-
if (!isRecord$
|
|
963
|
+
if (!isRecord$3(value) || value.kind !== 'file')
|
|
964
964
|
return false;
|
|
965
965
|
if (isNonEmptyString$1(value.handleId)) {
|
|
966
966
|
return hasOnlyKeys(value, ['kind', 'handleId']);
|
|
@@ -1027,7 +1027,7 @@ function isMiniProgramFileRef(value) {
|
|
|
1027
1027
|
* @see [DirectoryHandle](/reference/symbols/root/interfaces/DirectoryHandle) 使用目录引用的公开路径操作代理。
|
|
1028
1028
|
*/
|
|
1029
1029
|
function isMiniProgramDirectoryRef(value) {
|
|
1030
|
-
if (!isRecord$
|
|
1030
|
+
if (!isRecord$3(value) || value.kind !== 'directory')
|
|
1031
1031
|
return false;
|
|
1032
1032
|
if (isNonEmptyString$1(value.handleId)) {
|
|
1033
1033
|
return hasOnlyKeys(value, ['kind', 'handleId']);
|
|
@@ -1146,7 +1146,7 @@ function isMiniProgramByteArray(value) {
|
|
|
1146
1146
|
* @see [FileHandle](/reference/symbols/root/interfaces/FileHandle) 提供 `stat()` 的当前 session 文件代理。
|
|
1147
1147
|
*/
|
|
1148
1148
|
function isMiniProgramFileStat(value) {
|
|
1149
|
-
return (isRecord$
|
|
1149
|
+
return (isRecord$3(value) &&
|
|
1150
1150
|
value.kind === 'file' &&
|
|
1151
1151
|
isNonNegativeSafeInteger(value.size) &&
|
|
1152
1152
|
(value.modifiedAt === undefined || isNonNegativeFiniteNumber(value.modifiedAt)) &&
|
|
@@ -1206,7 +1206,7 @@ function isMiniProgramFileStat(value) {
|
|
|
1206
1206
|
* @see [isMiniProgramBridgeMessage](/reference/symbols/protocol/functions/isMiniProgramBridgeMessage) operation progress envelope 的最低校验。
|
|
1207
1207
|
*/
|
|
1208
1208
|
function isMiniProgramDownloadProgressPayload(value) {
|
|
1209
|
-
if (!isRecord$
|
|
1209
|
+
if (!isRecord$3(value) ||
|
|
1210
1210
|
!isNonNegativeSafeInteger(value.loaded) ||
|
|
1211
1211
|
typeof value.lengthComputable !== 'boolean' ||
|
|
1212
1212
|
!hasOnlyKeys(value, ['loaded', 'total', 'lengthComputable'])) {
|
|
@@ -1217,7 +1217,7 @@ function isMiniProgramDownloadProgressPayload(value) {
|
|
|
1217
1217
|
return isNonNegativeSafeInteger(value.total) && value.loaded <= value.total;
|
|
1218
1218
|
}
|
|
1219
1219
|
function isMiniProgramCompanionPrepareProgress(value) {
|
|
1220
|
-
if (!isRecord$
|
|
1220
|
+
if (!isRecord$3(value))
|
|
1221
1221
|
return false;
|
|
1222
1222
|
if (value.phase === 'downloading') {
|
|
1223
1223
|
return (isNonNegativeSafeInteger(value.loaded) &&
|
|
@@ -1235,10 +1235,10 @@ function isMiniProgramOperationProgressPayload(value) {
|
|
|
1235
1235
|
return isMiniProgramDownloadProgressPayload(value) || isMiniProgramCompanionPrepareProgress(value);
|
|
1236
1236
|
}
|
|
1237
1237
|
function isSDKHandshakePayload(value) {
|
|
1238
|
-
return isRecord$
|
|
1238
|
+
return isRecord$3(value) && isNonEmptyString$1(value.href) && typeof value.userAgent === 'string' && isNonEmptyString$1(value.sdkVersion);
|
|
1239
1239
|
}
|
|
1240
1240
|
function isBridgeError(value) {
|
|
1241
|
-
return isRecord$
|
|
1241
|
+
return isRecord$3(value) && isNonEmptyString$1(value.code) && typeof value.message === 'string';
|
|
1242
1242
|
}
|
|
1243
1243
|
function isNonNegativeSafeInteger(value) {
|
|
1244
1244
|
return typeof value === 'number' && Number.isSafeInteger(value) && value >= 0;
|
|
@@ -1253,15 +1253,10 @@ function hasOnlyKeys(value, allowedKeys) {
|
|
|
1253
1253
|
const allowed = new Set(allowedKeys);
|
|
1254
1254
|
return Object.keys(value).every((key) => allowed.has(key));
|
|
1255
1255
|
}
|
|
1256
|
-
function isRecord$
|
|
1256
|
+
function isRecord$3(value) {
|
|
1257
1257
|
return typeof value === 'object' && value !== null && !Array.isArray(value);
|
|
1258
1258
|
}
|
|
1259
1259
|
|
|
1260
|
-
/** 当前用户信息与登录能力支持的完整 scope 目录(canonical 顺序)。 */
|
|
1261
|
-
const USER_INFO_AUTHORIZATION_SCOPES = ['identity', 'profile', 'steam_account'];
|
|
1262
|
-
/** Companion alias 的跨构建、Runtime 与 Host 规范。 */
|
|
1263
|
-
const COMPANION_ALIAS_PATTERN = /^[a-z][a-z0-9-]{0,31}$/;
|
|
1264
|
-
|
|
1265
1260
|
const MINI_PROGRAM_PERMISSION_KEYS = [
|
|
1266
1261
|
'userInfo',
|
|
1267
1262
|
'steamLibrary',
|
|
@@ -1277,6 +1272,11 @@ new Set(MINI_PROGRAM_PERMISSION_KEYS);
|
|
|
1277
1272
|
|
|
1278
1273
|
new Set(MINI_PROGRAM_PERMISSION_KEYS);
|
|
1279
1274
|
|
|
1275
|
+
/** 当前用户信息与登录能力支持的完整 scope 目录(canonical 顺序)。 */
|
|
1276
|
+
const USER_INFO_AUTHORIZATION_SCOPES = ['identity', 'profile', 'steam_account'];
|
|
1277
|
+
/** Companion alias 的跨构建、Runtime 与 Host 规范。 */
|
|
1278
|
+
const COMPANION_ALIAS_PATTERN = /^[a-z][a-z0-9-]{0,31}$/;
|
|
1279
|
+
|
|
1280
1280
|
/** 获取浏览器全局 window。 */
|
|
1281
1281
|
function getGlobalWindow() {
|
|
1282
1282
|
return typeof window === 'undefined' ? undefined : window;
|
|
@@ -1338,7 +1338,7 @@ function createMessageId() {
|
|
|
1338
1338
|
/** 构建时替换为当前发布包的实际版本。 */
|
|
1339
1339
|
const HB_SDK_VERSION = typeof undefined === 'string'
|
|
1340
1340
|
? undefined
|
|
1341
|
-
: '0.8.3-alpha.
|
|
1341
|
+
: '0.8.3-alpha.5';
|
|
1342
1342
|
|
|
1343
1343
|
const RUNTIME_MODES = new Set(['production', 'preview', 'development', 'unknown']);
|
|
1344
1344
|
const OPERATING_SYSTEM_NAMES = new Set(['android', 'ios', 'ohos', 'windows', 'macos', 'linux', 'unknown']);
|
package/dist/protocol.cjs.js
CHANGED
|
@@ -444,7 +444,7 @@ const MINI_PROGRAM_PROTOCOL_CAPABILITIES = [
|
|
|
444
444
|
* @see [parseMiniProgramRuntimePermissions](/reference/symbols/protocol/functions/parseMiniProgramRuntimePermissions) Runtime 权限快照解析器。
|
|
445
445
|
*/
|
|
446
446
|
function isMiniProgramBridgeMessage(value) {
|
|
447
|
-
if (!isRecord$
|
|
447
|
+
if (!isRecord$3(value))
|
|
448
448
|
return false;
|
|
449
449
|
if (value.namespace !== MINI_PROGRAM_MESSAGE_NAMESPACE || (value.version !== 1 && value.version !== 2) || !isNonEmptyString$1(value.nonce)) {
|
|
450
450
|
return false;
|
|
@@ -594,7 +594,7 @@ function isMiniProgramRelativePath(value) {
|
|
|
594
594
|
* @see [DirectoryHandle](/reference/symbols/root/interfaces/DirectoryHandle) 可作为 derived path root 的目录代理。
|
|
595
595
|
*/
|
|
596
596
|
function isMiniProgramPathRootRef(value) {
|
|
597
|
-
if (!isRecord$
|
|
597
|
+
if (!isRecord$3(value))
|
|
598
598
|
return false;
|
|
599
599
|
if (value.kind === 'sandbox')
|
|
600
600
|
return hasOnlyKeys(value, ['kind']);
|
|
@@ -660,7 +660,7 @@ function isMiniProgramPathRootRef(value) {
|
|
|
660
660
|
* @see [FileHandle](/reference/symbols/root/interfaces/FileHandle) 使用文件引用的公开 I/O 代理。
|
|
661
661
|
*/
|
|
662
662
|
function isMiniProgramFileRef(value) {
|
|
663
|
-
if (!isRecord$
|
|
663
|
+
if (!isRecord$3(value) || value.kind !== 'file')
|
|
664
664
|
return false;
|
|
665
665
|
if (isNonEmptyString$1(value.handleId)) {
|
|
666
666
|
return hasOnlyKeys(value, ['kind', 'handleId']);
|
|
@@ -727,7 +727,7 @@ function isMiniProgramFileRef(value) {
|
|
|
727
727
|
* @see [DirectoryHandle](/reference/symbols/root/interfaces/DirectoryHandle) 使用目录引用的公开路径操作代理。
|
|
728
728
|
*/
|
|
729
729
|
function isMiniProgramDirectoryRef(value) {
|
|
730
|
-
if (!isRecord$
|
|
730
|
+
if (!isRecord$3(value) || value.kind !== 'directory')
|
|
731
731
|
return false;
|
|
732
732
|
if (isNonEmptyString$1(value.handleId)) {
|
|
733
733
|
return hasOnlyKeys(value, ['kind', 'handleId']);
|
|
@@ -801,7 +801,7 @@ function isMiniProgramDirectoryRef(value) {
|
|
|
801
801
|
* @see [SaveFileResult](/reference/symbols/protocol/types/SaveFileResult) save picker 的 direct-ref 文件结果。
|
|
802
802
|
*/
|
|
803
803
|
function isMiniProgramFileDescriptor(value) {
|
|
804
|
-
return (isRecord$
|
|
804
|
+
return (isRecord$3(value) &&
|
|
805
805
|
value.kind === 'file' &&
|
|
806
806
|
isNonEmptyString$1(value.name) &&
|
|
807
807
|
isFileMode(value.mode) &&
|
|
@@ -871,7 +871,7 @@ function isMiniProgramFileDescriptor(value) {
|
|
|
871
871
|
* @see [PickDirectoryResult](/reference/symbols/protocol/types/PickDirectoryResult) picker 的 direct-ref 返回契约。
|
|
872
872
|
*/
|
|
873
873
|
function isMiniProgramDirectoryDescriptor(value) {
|
|
874
|
-
return (isRecord$
|
|
874
|
+
return (isRecord$3(value) &&
|
|
875
875
|
value.kind === 'directory' &&
|
|
876
876
|
isNonEmptyString$1(value.name) &&
|
|
877
877
|
isFileMode(value.mode) &&
|
|
@@ -1050,7 +1050,7 @@ function isMiniProgramByteArray(value) {
|
|
|
1050
1050
|
* @see [FileHandle](/reference/symbols/root/interfaces/FileHandle) 提供 `stat()` 的当前 session 文件代理。
|
|
1051
1051
|
*/
|
|
1052
1052
|
function isMiniProgramFileStat(value) {
|
|
1053
|
-
return (isRecord$
|
|
1053
|
+
return (isRecord$3(value) &&
|
|
1054
1054
|
value.kind === 'file' &&
|
|
1055
1055
|
isNonNegativeSafeInteger(value.size) &&
|
|
1056
1056
|
(value.modifiedAt === undefined || isNonNegativeFiniteNumber(value.modifiedAt)) &&
|
|
@@ -1110,7 +1110,7 @@ function isMiniProgramFileStat(value) {
|
|
|
1110
1110
|
* @see [isMiniProgramBridgeMessage](/reference/symbols/protocol/functions/isMiniProgramBridgeMessage) operation progress envelope 的最低校验。
|
|
1111
1111
|
*/
|
|
1112
1112
|
function isMiniProgramDownloadProgressPayload(value) {
|
|
1113
|
-
if (!isRecord$
|
|
1113
|
+
if (!isRecord$3(value) ||
|
|
1114
1114
|
!isNonNegativeSafeInteger(value.loaded) ||
|
|
1115
1115
|
typeof value.lengthComputable !== 'boolean' ||
|
|
1116
1116
|
!hasOnlyKeys(value, ['loaded', 'total', 'lengthComputable'])) {
|
|
@@ -1121,7 +1121,7 @@ function isMiniProgramDownloadProgressPayload(value) {
|
|
|
1121
1121
|
return isNonNegativeSafeInteger(value.total) && value.loaded <= value.total;
|
|
1122
1122
|
}
|
|
1123
1123
|
function isMiniProgramCompanionPrepareProgress(value) {
|
|
1124
|
-
if (!isRecord$
|
|
1124
|
+
if (!isRecord$3(value))
|
|
1125
1125
|
return false;
|
|
1126
1126
|
if (value.phase === 'downloading') {
|
|
1127
1127
|
return (isNonNegativeSafeInteger(value.loaded) &&
|
|
@@ -1139,10 +1139,10 @@ function isMiniProgramOperationProgressPayload(value) {
|
|
|
1139
1139
|
return isMiniProgramDownloadProgressPayload(value) || isMiniProgramCompanionPrepareProgress(value);
|
|
1140
1140
|
}
|
|
1141
1141
|
function isSDKHandshakePayload(value) {
|
|
1142
|
-
return isRecord$
|
|
1142
|
+
return isRecord$3(value) && isNonEmptyString$1(value.href) && typeof value.userAgent === 'string' && isNonEmptyString$1(value.sdkVersion);
|
|
1143
1143
|
}
|
|
1144
1144
|
function isBridgeError(value) {
|
|
1145
|
-
return isRecord$
|
|
1145
|
+
return isRecord$3(value) && isNonEmptyString$1(value.code) && typeof value.message === 'string';
|
|
1146
1146
|
}
|
|
1147
1147
|
function isFileMode(value) {
|
|
1148
1148
|
return value === 'read' || value === 'readwrite';
|
|
@@ -1160,13 +1160,10 @@ function hasOnlyKeys(value, allowedKeys) {
|
|
|
1160
1160
|
const allowed = new Set(allowedKeys);
|
|
1161
1161
|
return Object.keys(value).every((key) => allowed.has(key));
|
|
1162
1162
|
}
|
|
1163
|
-
function isRecord$
|
|
1163
|
+
function isRecord$3(value) {
|
|
1164
1164
|
return typeof value === 'object' && value !== null && !Array.isArray(value);
|
|
1165
1165
|
}
|
|
1166
1166
|
|
|
1167
|
-
/** 当前用户信息与登录能力支持的完整 scope 目录(canonical 顺序)。 */
|
|
1168
|
-
const USER_INFO_AUTHORIZATION_SCOPES = ['identity', 'profile', 'steam_account'];
|
|
1169
|
-
|
|
1170
1167
|
const MINI_PROGRAM_PERMISSION_KEYS = [
|
|
1171
1168
|
'userInfo',
|
|
1172
1169
|
'steamLibrary',
|
|
@@ -1310,7 +1307,7 @@ function isManagedMiniProgramRuntimePermissionKey(key) {
|
|
|
1310
1307
|
* @see {@link https://docs.xiaoheihe.cn/hb_sdk/guide/permissions | 权限声明}
|
|
1311
1308
|
*/
|
|
1312
1309
|
function parseMiniProgramRuntimePermissions(snapshot) {
|
|
1313
|
-
if (!isRecord(snapshot) || snapshot.schema_version !== 1 || !Array.isArray(snapshot.entries)) {
|
|
1310
|
+
if (!isRecord$2(snapshot) || snapshot.schema_version !== 1 || !Array.isArray(snapshot.entries)) {
|
|
1314
1311
|
return { valid: false, permissions: {} };
|
|
1315
1312
|
}
|
|
1316
1313
|
if (snapshot.revision !== undefined && (typeof snapshot.revision !== 'number' || !Number.isInteger(snapshot.revision) || snapshot.revision < 0)) {
|
|
@@ -1319,7 +1316,7 @@ function parseMiniProgramRuntimePermissions(snapshot) {
|
|
|
1319
1316
|
const seenKeys = new Set();
|
|
1320
1317
|
const permissions = {};
|
|
1321
1318
|
for (const rawEntry of snapshot.entries) {
|
|
1322
|
-
if (!isRecord(rawEntry) || typeof rawEntry.key !== 'string' || !rawEntry.key.trim()) {
|
|
1319
|
+
if (!isRecord$2(rawEntry) || typeof rawEntry.key !== 'string' || !rawEntry.key.trim()) {
|
|
1323
1320
|
return { valid: false, permissions: {} };
|
|
1324
1321
|
}
|
|
1325
1322
|
const inputKey = rawEntry.key.trim();
|
|
@@ -1335,7 +1332,7 @@ function parseMiniProgramRuntimePermissions(snapshot) {
|
|
|
1335
1332
|
}
|
|
1336
1333
|
if (key === 'network') {
|
|
1337
1334
|
const config = rawEntry.config;
|
|
1338
|
-
if (!isRecord(config) || typeof config.useOfficialDomain !== 'boolean') {
|
|
1335
|
+
if (!isRecord$2(config) || typeof config.useOfficialDomain !== 'boolean') {
|
|
1339
1336
|
return { valid: false, permissions: {} };
|
|
1340
1337
|
}
|
|
1341
1338
|
permissions[key] = {
|
|
@@ -1345,7 +1342,7 @@ function parseMiniProgramRuntimePermissions(snapshot) {
|
|
|
1345
1342
|
};
|
|
1346
1343
|
continue;
|
|
1347
1344
|
}
|
|
1348
|
-
if (rawEntry.config !== null && rawEntry.config !== undefined && (!isRecord(rawEntry.config) || Object.keys(rawEntry.config).length > 0)) {
|
|
1345
|
+
if (rawEntry.config !== null && rawEntry.config !== undefined && (!isRecord$2(rawEntry.config) || Object.keys(rawEntry.config).length > 0)) {
|
|
1349
1346
|
return { valid: false, permissions: {} };
|
|
1350
1347
|
}
|
|
1351
1348
|
permissions[key] = {
|
|
@@ -1356,10 +1353,13 @@ function parseMiniProgramRuntimePermissions(snapshot) {
|
|
|
1356
1353
|
}
|
|
1357
1354
|
return { valid: true, permissions };
|
|
1358
1355
|
}
|
|
1359
|
-
function isRecord(value) {
|
|
1356
|
+
function isRecord$2(value) {
|
|
1360
1357
|
return typeof value === 'object' && value !== null && !Array.isArray(value);
|
|
1361
1358
|
}
|
|
1362
1359
|
|
|
1360
|
+
/** 当前用户信息与登录能力支持的完整 scope 目录(canonical 顺序)。 */
|
|
1361
|
+
const USER_INFO_AUTHORIZATION_SCOPES = ['identity', 'profile', 'steam_account'];
|
|
1362
|
+
|
|
1363
1363
|
exports.AUTH_LOGIN_METHOD = AUTH_LOGIN_METHOD;
|
|
1364
1364
|
exports.CLOUD_LEADERBOARD_DELETE_CURRENT_USER_ENTRY_METHOD = CLOUD_LEADERBOARD_DELETE_CURRENT_USER_ENTRY_METHOD;
|
|
1365
1365
|
exports.CLOUD_LEADERBOARD_GET_CURRENT_USER_ENTRY_METHOD = CLOUD_LEADERBOARD_GET_CURRENT_USER_ENTRY_METHOD;
|