diff --git a/packages/uni-components/src/components/button/index.tsx b/packages/uni-components/src/components/button/index.tsx index f79e10e5fd37f0e67cdb517c967645c3c2f90fad..723f6ebbeb1be93d02bdf92f656707b5f73c0262 100644 --- a/packages/uni-components/src/components/button/index.tsx +++ b/packages/uni-components/src/components/button/index.tsx @@ -3,13 +3,12 @@ import { useI18n, initI18nButtonMsgsOnce } from '@dcloudio/uni-core' import { defineBuiltInComponent } from '../../helpers/component' import { useHover } from '../../helpers/useHover' import { useBooleanAttr } from '../../helpers/useBooleanAttr' +import { withWebEvent } from '../../helpers/useEvent' import { UniFormCtx, uniFormKey } from '../form' import { uniLabelKey, UniLabelCtx } from '../label' import { useListeners } from '../../helpers/useListeners' -import { useAttrs } from '../../helpers/useAttrs' export default /*#__PURE__*/ defineBuiltInComponent({ - inheritAttrs: false, name: 'Button', props: { id: { @@ -44,8 +43,12 @@ export default /*#__PURE__*/ defineBuiltInComponent({ type: String, default: '', }, + loading: { + type: [Boolean, String], + default: false, + }, }, - setup(props, { slots, emit }) { + setup(props, { slots }) { const rootRef = ref(null) if (__PLATFORM__ === 'app') { initI18nButtonMsgsOnce() @@ -56,9 +59,9 @@ export default /*#__PURE__*/ defineBuiltInComponent({ ) const { hovering, binding } = useHover(props) const { t } = useI18n() - const onClick = (e: Event, isLabelClick: boolean) => { + const onClick = withWebEvent((e: Event, isLabelClick: boolean) => { if (props.disabled) { - return + return e.stopImmediatePropagation() } if (isLabelClick) { rootRef.value!.click() @@ -81,13 +84,13 @@ export default /*#__PURE__*/ defineBuiltInComponent({ t('uni.button.feedback.send') ) } - } + }) const uniLabel = inject( uniLabelKey, false as unknown as UniLabelCtx ) - if (!!uniLabel) { + if (uniLabel) { uniLabel.addHandler(onClick) onBeforeUnmount(() => { uniLabel.removeHandler(onClick) @@ -95,23 +98,10 @@ export default /*#__PURE__*/ defineBuiltInComponent({ } useListeners(props, { 'label-click': onClick }) - const { $listeners, $attrs, $excludeAttrs } = useAttrs({ - excludeListeners: true, - }) - const _listeners = Object.create(null) - let events = ['onClick', 'onTap'] - if ($listeners.value) { - Object.keys($listeners.value).forEach((e) => { - if (props.disabled && events.includes(e)) { - return - } - _listeners[e] = ($listeners.value as any)[e] - }) - } - return () => { const hoverClass = props.hoverClass const booleanAttrs = useBooleanAttr(props, 'disabled') + const loadingAttrs = useBooleanAttr(props, 'loading') const hasHoverClass = hoverClass && hoverClass !== 'none' return ( @@ -121,9 +111,7 @@ export default /*#__PURE__*/ defineBuiltInComponent({ class={hasHoverClass && hovering.value ? hoverClass : ''} {...(hasHoverClass && binding)} {...booleanAttrs} - {..._listeners} - {...$attrs.value} - {...$excludeAttrs.value} + {...loadingAttrs} > {slots.default && slots.default()} @@ -151,7 +139,7 @@ function openFeedback(titleText: string, sendText: string) { fontWeight: 'bold', onclick: function () { feedback.evalJS( - 'mui&&mui.trigger(document.getElementById("submit"),"tap")' + 'typeof mui !== "undefined" && mui.trigger(document.getElementById("submit"),"tap")' ) }, }, diff --git a/packages/uni-components/src/helpers/useEvent.ts b/packages/uni-components/src/helpers/useEvent.ts index 80006576de936b394af8315813173d9ca1714675..1f0258c1993b8b32c55540b0081930f7f1b5c42c 100644 --- a/packages/uni-components/src/helpers/useEvent.ts +++ b/packages/uni-components/src/helpers/useEvent.ts @@ -7,7 +7,7 @@ export type CustomEventTrigger = ReturnType export type NativeEventTrigger = ReturnType export type EmitEvent any> = [Parameters[0]] -export function withWebEvent(fn: (e: any) => any) { +export function withWebEvent(fn: (...args: any[]) => any) { return ((fn as any).__wwe = true), fn } diff --git a/packages/uni-h5/dist/uni-h5.cjs.js b/packages/uni-h5/dist/uni-h5.cjs.js index b3994c99ee4c3bf7a4c77735c2393871a4bfc7ef..f1ca8925c5d493c8dfe217fa45f91cd5b4c96447 100644 --- a/packages/uni-h5/dist/uni-h5.cjs.js +++ b/packages/uni-h5/dist/uni-h5.cjs.js @@ -1131,6 +1131,31 @@ function useBooleanAttr(props2, keys) { return res; }, Object.create(null)); } +function withWebEvent(fn) { + return fn.__wwe = true, fn; +} +function useCustomEvent(ref, emit2) { + return (name, evt, detail) => { + if (ref.value) { + emit2(name, normalizeCustomEvent(name, evt, ref.value, detail || {})); + } + }; +} +function useNativeEvent(emit2) { + return (name, evt) => { + emit2(name, createNativeEvent(evt)); + }; +} +function normalizeCustomEvent(name, domEvt, el, detail) { + const target = uniShared.normalizeTarget(el); + return { + type: detail.type || name, + timeStamp: domEvt.timeStamp || 0, + target, + currentTarget: target, + detail + }; +} const uniFormKey = PolySymbol(process.env.NODE_ENV !== "production" ? "uniForm" : "uf"); var index$r = /* @__PURE__ */ defineBuiltInComponent({ name: "Form", @@ -1171,31 +1196,6 @@ function provideForm(emit2) { }); return fields2; } -function withWebEvent(fn) { - return fn.__wwe = true, fn; -} -function useCustomEvent(ref, emit2) { - return (name, evt, detail) => { - if (ref.value) { - emit2(name, normalizeCustomEvent(name, evt, ref.value, detail || {})); - } - }; -} -function useNativeEvent(emit2) { - return (name, evt) => { - emit2(name, createNativeEvent(evt)); - }; -} -function normalizeCustomEvent(name, domEvt, el, detail) { - const target = uniShared.normalizeTarget(el); - return { - type: detail.type || name, - timeStamp: domEvt.timeStamp || 0, - target, - currentTarget: target, - detail - }; -} const uniLabelKey = PolySymbol(process.env.NODE_ENV !== "production" ? "uniLabel" : "ul"); const props$p = { for: { @@ -1247,45 +1247,7 @@ function useProvideLabel() { }); return handlers; } -function entries(obj) { - return Object.keys(obj).map((key) => [key, obj[key]]); -} -const DEFAULT_EXCLUDE_KEYS = ["class", "style"]; -const LISTENER_PREFIX = /^on[A-Z]+/; -const useAttrs = (params = {}) => { - const {excludeListeners = false, excludeKeys = []} = params; - const instance = vue.getCurrentInstance(); - const attrs = vue.shallowRef({}); - const listeners = vue.shallowRef({}); - const excludeAttrs = vue.shallowRef({}); - const allExcludeKeys = excludeKeys.concat(DEFAULT_EXCLUDE_KEYS); - instance.attrs = vue.reactive(instance.attrs); - vue.watchEffect(() => { - const res = entries(instance.attrs).reduce((acc, [key, val]) => { - if (allExcludeKeys.includes(key)) { - acc.exclude[key] = val; - } else if (LISTENER_PREFIX.test(key)) { - if (!excludeListeners) { - acc.attrs[key] = val; - } - acc.listeners[key] = val; - } else { - acc.attrs[key] = val; - } - return acc; - }, { - exclude: {}, - attrs: {}, - listeners: {} - }); - attrs.value = res.attrs; - listeners.value = res.listeners; - excludeAttrs.value = res.exclude; - }); - return {$attrs: attrs, $listeners: listeners, $excludeAttrs: excludeAttrs}; -}; var index$p = /* @__PURE__ */ defineBuiltInComponent({ - inheritAttrs: false, name: "Button", props: { id: { @@ -1319,11 +1281,14 @@ var index$p = /* @__PURE__ */ defineBuiltInComponent({ openType: { type: String, default: "" + }, + loading: { + type: [Boolean, String], + default: false } }, setup(props2, { - slots, - emit: emit2 + slots }) { const rootRef = vue.ref(null); const uniForm = vue.inject(uniFormKey, false); @@ -1332,9 +1297,9 @@ var index$p = /* @__PURE__ */ defineBuiltInComponent({ binding } = useHover(props2); useI18n(); - const onClick = (e2, isLabelClick) => { + const onClick = withWebEvent((e2, isLabelClick) => { if (props2.disabled) { - return; + return e2.stopImmediatePropagation(); } if (isLabelClick) { rootRef.value.click(); @@ -1351,37 +1316,21 @@ var index$p = /* @__PURE__ */ defineBuiltInComponent({ } return; } - }; + }); const uniLabel = vue.inject(uniLabelKey, false); - if (!!uniLabel) { + if (uniLabel) { uniLabel.addHandler(onClick); } - const { - $listeners, - $attrs, - $excludeAttrs - } = useAttrs({ - excludeListeners: true - }); - const _listeners = Object.create(null); - let events = ["onClick", "onTap"]; - if ($listeners.value) { - Object.keys($listeners.value).forEach((e2) => { - if (props2.disabled && events.includes(e2)) { - return; - } - _listeners[e2] = $listeners.value[e2]; - }); - } return () => { const hoverClass = props2.hoverClass; const booleanAttrs = useBooleanAttr(props2, "disabled"); + const loadingAttrs = useBooleanAttr(props2, "loading"); const hasHoverClass = hoverClass && hoverClass !== "none"; return vue.createVNode("uni-button", vue.mergeProps({ "ref": rootRef, "onClick": onClick, "class": hasHoverClass && hovering.value ? hoverClass : "" - }, hasHoverClass && binding, booleanAttrs, _listeners, $attrs.value, $excludeAttrs.value), [slots.default && slots.default()], 16, ["onClick"]); + }, hasHoverClass && binding, booleanAttrs, loadingAttrs), [slots.default && slots.default()], 16, ["onClick"]); }; } }); @@ -3054,6 +3003,43 @@ var Input = /* @__PURE__ */ defineBuiltInComponent({ }; } }); +function entries(obj) { + return Object.keys(obj).map((key) => [key, obj[key]]); +} +const DEFAULT_EXCLUDE_KEYS = ["class", "style"]; +const LISTENER_PREFIX = /^on[A-Z]+/; +const useAttrs = (params = {}) => { + const {excludeListeners = false, excludeKeys = []} = params; + const instance = vue.getCurrentInstance(); + const attrs = vue.shallowRef({}); + const listeners = vue.shallowRef({}); + const excludeAttrs = vue.shallowRef({}); + const allExcludeKeys = excludeKeys.concat(DEFAULT_EXCLUDE_KEYS); + instance.attrs = vue.reactive(instance.attrs); + vue.watchEffect(() => { + const res = entries(instance.attrs).reduce((acc, [key, val]) => { + if (allExcludeKeys.includes(key)) { + acc.exclude[key] = val; + } else if (LISTENER_PREFIX.test(key)) { + if (!excludeListeners) { + acc.attrs[key] = val; + } + acc.listeners[key] = val; + } else { + acc.attrs[key] = val; + } + return acc; + }, { + exclude: {}, + attrs: {}, + listeners: {} + }); + attrs.value = res.attrs; + listeners.value = res.listeners; + excludeAttrs.value = res.exclude; + }); + return {$attrs: attrs, $listeners: listeners, $excludeAttrs: excludeAttrs}; +}; function initScrollBounce() { } function disableScrollBounce({disable}) { diff --git a/packages/uni-h5/dist/uni-h5.es.js b/packages/uni-h5/dist/uni-h5.es.js index 6fa4869283a144bf1d138b37e396cdd803d892bd..84776118781bc162ec69f8db2d94e4f36924c9b0 100644 --- a/packages/uni-h5/dist/uni-h5.es.js +++ b/packages/uni-h5/dist/uni-h5.es.js @@ -1,5 +1,5 @@ import {isFunction, extend, hyphenate, isPlainObject, isString, isArray, hasOwn, isObject, capitalize, toRawType, makeMap as makeMap$1, isPromise, invokeArrayFns as invokeArrayFns$1} from "@vue/shared"; -import {injectHook, withModifiers, createVNode, getCurrentInstance, inject, provide, reactive, openBlock, createBlock, mergeProps, toDisplayString, defineComponent, ref, computed, watch, onUnmounted, shallowRef, watchEffect, onBeforeUnmount, onActivated, onMounted, nextTick, resolveComponent, toHandlers, renderSlot, onBeforeMount, withDirectives, vShow, isVNode, Fragment, markRaw, createCommentVNode, createTextVNode, onBeforeActivate, onBeforeDeactivate, renderList, onDeactivated, Teleport, createApp, Transition, withCtx, KeepAlive, resolveDynamicComponent} from "vue"; +import {injectHook, withModifiers, createVNode, getCurrentInstance, inject, provide, reactive, openBlock, createBlock, mergeProps, toDisplayString, defineComponent, ref, computed, watch, onUnmounted, onBeforeUnmount, onActivated, onMounted, nextTick, resolveComponent, toHandlers, renderSlot, onBeforeMount, withDirectives, vShow, shallowRef, watchEffect, isVNode, Fragment, markRaw, createCommentVNode, createTextVNode, onBeforeActivate, onBeforeDeactivate, renderList, onDeactivated, Teleport, createApp, Transition, withCtx, KeepAlive, resolveDynamicComponent} from "vue"; import {once, passive, normalizeTarget, isBuiltInComponent, initCostomDataset, invokeArrayFns, NAVBAR_HEIGHT, parseQuery, PRIMARY_COLOR, debounce, getCostomDataset, callOptions, removeLeadingSlash, getLen, ON_REACH_BOTTOM_DISTANCE, decodedQuery, updateElementStyle, addFont, scrollTo, formatDateTime} from "@dcloudio/uni-shared"; import {initVueI18n, LOCALE_EN, LOCALE_ES, LOCALE_FR, LOCALE_ZH_HANS, LOCALE_ZH_HANT} from "@dcloudio/uni-i18n"; import {useRoute, createRouter, createWebHistory, createWebHashHistory, useRouter, isNavigationFailure, RouterView} from "vue-router"; @@ -594,7 +594,7 @@ var safeAreaInsets = { onChange, offChange }; -var out = safeAreaInsets; +var D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out = safeAreaInsets; const onEventPrevent = /* @__PURE__ */ withModifiers(() => { }, ["prevent"]); const onEventStop = /* @__PURE__ */ withModifiers(() => { @@ -606,10 +606,10 @@ function getWindowOffset() { const left = parseInt(style.getPropertyValue("--window-left")); const right = parseInt(style.getPropertyValue("--window-right")); return { - top: top ? top + out.top : 0, - bottom: bottom ? bottom + out.bottom : 0, - left: left ? left + out.left : 0, - right: right ? right + out.right : 0 + top: top ? top + D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out.top : 0, + bottom: bottom ? bottom + D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out.bottom : 0, + left: left ? left + D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out.left : 0, + right: right ? right + D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out.right : 0 }; } function updateCssVar(cssVars) { @@ -1300,7 +1300,7 @@ function normalizePageMeta(pageMeta) { let offset = rpx2px(refreshOptions.offset); const {type} = navigationBar; if (type !== "transparent" && type !== "none") { - offset += NAVBAR_HEIGHT + out.top; + offset += NAVBAR_HEIGHT + D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out.top; } refreshOptions.offset = offset; refreshOptions.height = rpx2px(refreshOptions.height); @@ -2182,6 +2182,31 @@ function useBooleanAttr(props2, keys) { return res; }, Object.create(null)); } +function withWebEvent(fn) { + return fn.__wwe = true, fn; +} +function useCustomEvent(ref2, emit2) { + return (name, evt, detail) => { + if (ref2.value) { + emit2(name, normalizeCustomEvent(name, evt, ref2.value, detail || {})); + } + }; +} +function useNativeEvent(emit2) { + return (name, evt) => { + emit2(name, createNativeEvent(evt)); + }; +} +function normalizeCustomEvent(name, domEvt, el, detail) { + const target = normalizeTarget(el); + return { + type: detail.type || name, + timeStamp: domEvt.timeStamp || 0, + target, + currentTarget: target, + detail + }; +} const uniFormKey = PolySymbol(process.env.NODE_ENV !== "production" ? "uniForm" : "uf"); var index$o = /* @__PURE__ */ defineBuiltInComponent({ name: "Form", @@ -2222,31 +2247,6 @@ function provideForm(emit2) { }); return fields2; } -function withWebEvent(fn) { - return fn.__wwe = true, fn; -} -function useCustomEvent(ref2, emit2) { - return (name, evt, detail) => { - if (ref2.value) { - emit2(name, normalizeCustomEvent(name, evt, ref2.value, detail || {})); - } - }; -} -function useNativeEvent(emit2) { - return (name, evt) => { - emit2(name, createNativeEvent(evt)); - }; -} -function normalizeCustomEvent(name, domEvt, el, detail) { - const target = normalizeTarget(el); - return { - type: detail.type || name, - timeStamp: domEvt.timeStamp || 0, - target, - currentTarget: target, - detail - }; -} const uniLabelKey = PolySymbol(process.env.NODE_ENV !== "production" ? "uniLabel" : "ul"); const props$w = { for: { @@ -2352,45 +2352,7 @@ function _removeListeners(id2, listeners, watch2) { } }); } -function entries(obj) { - return Object.keys(obj).map((key) => [key, obj[key]]); -} -const DEFAULT_EXCLUDE_KEYS = ["class", "style"]; -const LISTENER_PREFIX = /^on[A-Z]+/; -const useAttrs = (params = {}) => { - const {excludeListeners = false, excludeKeys = []} = params; - const instance2 = getCurrentInstance(); - const attrs2 = shallowRef({}); - const listeners = shallowRef({}); - const excludeAttrs = shallowRef({}); - const allExcludeKeys = excludeKeys.concat(DEFAULT_EXCLUDE_KEYS); - instance2.attrs = reactive(instance2.attrs); - watchEffect(() => { - const res = entries(instance2.attrs).reduce((acc, [key, val]) => { - if (allExcludeKeys.includes(key)) { - acc.exclude[key] = val; - } else if (LISTENER_PREFIX.test(key)) { - if (!excludeListeners) { - acc.attrs[key] = val; - } - acc.listeners[key] = val; - } else { - acc.attrs[key] = val; - } - return acc; - }, { - exclude: {}, - attrs: {}, - listeners: {} - }); - attrs2.value = res.attrs; - listeners.value = res.listeners; - excludeAttrs.value = res.exclude; - }); - return {$attrs: attrs2, $listeners: listeners, $excludeAttrs: excludeAttrs}; -}; var index$m = /* @__PURE__ */ defineBuiltInComponent({ - inheritAttrs: false, name: "Button", props: { id: { @@ -2424,11 +2386,14 @@ var index$m = /* @__PURE__ */ defineBuiltInComponent({ openType: { type: String, default: "" + }, + loading: { + type: [Boolean, String], + default: false } }, setup(props2, { - slots, - emit: emit2 + slots }) { const rootRef = ref(null); const uniForm = inject(uniFormKey, false); @@ -2437,9 +2402,9 @@ var index$m = /* @__PURE__ */ defineBuiltInComponent({ binding } = useHover(props2); useI18n(); - const onClick = (e2, isLabelClick) => { + const onClick = withWebEvent((e2, isLabelClick) => { if (props2.disabled) { - return; + return e2.stopImmediatePropagation(); } if (isLabelClick) { rootRef.value.click(); @@ -2456,9 +2421,9 @@ var index$m = /* @__PURE__ */ defineBuiltInComponent({ } return; } - }; + }); const uniLabel = inject(uniLabelKey, false); - if (!!uniLabel) { + if (uniLabel) { uniLabel.addHandler(onClick); onBeforeUnmount(() => { uniLabel.removeHandler(onClick); @@ -2467,32 +2432,16 @@ var index$m = /* @__PURE__ */ defineBuiltInComponent({ useListeners(props2, { "label-click": onClick }); - const { - $listeners, - $attrs, - $excludeAttrs - } = useAttrs({ - excludeListeners: true - }); - const _listeners = Object.create(null); - let events = ["onClick", "onTap"]; - if ($listeners.value) { - Object.keys($listeners.value).forEach((e2) => { - if (props2.disabled && events.includes(e2)) { - return; - } - _listeners[e2] = $listeners.value[e2]; - }); - } return () => { const hoverClass = props2.hoverClass; const booleanAttrs = useBooleanAttr(props2, "disabled"); + const loadingAttrs = useBooleanAttr(props2, "loading"); const hasHoverClass = hoverClass && hoverClass !== "none"; return createVNode("uni-button", mergeProps({ "ref": rootRef, "onClick": onClick, "class": hasHoverClass && hovering.value ? hoverClass : "" - }, hasHoverClass && binding, booleanAttrs, _listeners, $attrs.value, $excludeAttrs.value), [slots.default && slots.default()], 16, ["onClick"]); + }, hasHoverClass && binding, booleanAttrs, loadingAttrs), [slots.default && slots.default()], 16, ["onClick"]); }; } }); @@ -4937,6 +4886,43 @@ var Input = /* @__PURE__ */ defineBuiltInComponent({ }; } }); +function entries(obj) { + return Object.keys(obj).map((key) => [key, obj[key]]); +} +const DEFAULT_EXCLUDE_KEYS = ["class", "style"]; +const LISTENER_PREFIX = /^on[A-Z]+/; +const useAttrs = (params = {}) => { + const {excludeListeners = false, excludeKeys = []} = params; + const instance2 = getCurrentInstance(); + const attrs2 = shallowRef({}); + const listeners = shallowRef({}); + const excludeAttrs = shallowRef({}); + const allExcludeKeys = excludeKeys.concat(DEFAULT_EXCLUDE_KEYS); + instance2.attrs = reactive(instance2.attrs); + watchEffect(() => { + const res = entries(instance2.attrs).reduce((acc, [key, val]) => { + if (allExcludeKeys.includes(key)) { + acc.exclude[key] = val; + } else if (LISTENER_PREFIX.test(key)) { + if (!excludeListeners) { + acc.attrs[key] = val; + } + acc.listeners[key] = val; + } else { + acc.attrs[key] = val; + } + return acc; + }, { + exclude: {}, + attrs: {}, + listeners: {} + }); + attrs2.value = res.attrs; + listeners.value = res.listeners; + excludeAttrs.value = res.exclude; + }); + return {$attrs: attrs2, $listeners: listeners, $excludeAttrs: excludeAttrs}; +}; function initScrollBounce() { } function disableScrollBounce({disable}) { @@ -14928,7 +14914,7 @@ const getSystemInfoSync = /* @__PURE__ */ defineSyncApi("getSystemInfoSync", () const windowWidth = getWindowWidth(screenWidth); let windowHeight = window.innerHeight; const language = navigator.language; - const statusBarHeight = out.top; + const statusBarHeight = D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out.top; let osname; let osversion; let model; @@ -15041,12 +15027,12 @@ const getSystemInfoSync = /* @__PURE__ */ defineSyncApi("getSystemInfoSync", () const system = `${osname} ${osversion}`; const platform = osname.toLocaleLowerCase(); const safeArea = { - left: out.left, - right: windowWidth - out.right, - top: out.top, - bottom: windowHeight - out.bottom, - width: windowWidth - out.left - out.right, - height: windowHeight - out.top - out.bottom + left: D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out.left, + right: windowWidth - D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out.right, + top: D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out.top, + bottom: windowHeight - D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out.bottom, + width: windowWidth - D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out.left - D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out.right, + height: windowHeight - D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out.top - D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out.bottom }; const {top: windowTop, bottom: windowBottom} = getWindowOffset(); windowHeight -= windowTop; @@ -15066,10 +15052,10 @@ const getSystemInfoSync = /* @__PURE__ */ defineSyncApi("getSystemInfoSync", () model, safeArea, safeAreaInsets: { - top: out.top, - right: out.right, - bottom: out.bottom, - left: out.left + top: D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out.top, + right: D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out.right, + bottom: D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out.bottom, + left: D__DCloud_local_git_uniAppNext_node_modules_safeAreaInsets_out.left } }; });