feat:"完成页面接口的对接"

This commit is contained in:
2026-01-29 17:58:19 +08:00
parent 2774a539bf
commit 2b69da3c15
98 changed files with 9504 additions and 592 deletions

View File

@@ -85,8 +85,8 @@ const def = (obj, key, value) => {
});
};
const looseToNumber = (val) => {
const n = parseFloat(val);
return isNaN(n) ? val : n;
const n2 = parseFloat(val);
return isNaN(n2) ? val : n2;
};
function normalizeStyle$1(value) {
if (isArray(value)) {
@@ -118,6 +118,26 @@ function parseStringStyle(cssText) {
});
return ret;
}
function normalizeClass$1(value) {
let res = "";
if (isString(value)) {
res = value;
} else if (isArray(value)) {
for (let i = 0; i < value.length; i++) {
const normalized = normalizeClass$1(value[i]);
if (normalized) {
res += normalized + " ";
}
}
} else if (isObject(value)) {
for (const name in value) {
if (value[name]) {
res += name + " ";
}
}
}
return res.trim();
}
const toDisplayString = (val) => {
return isString(val) ? val : val == null ? "" : isArray(val) || isObject(val) && (val.toString === objectToString || !isFunction(val.toString)) ? JSON.stringify(val, replacer, 2) : String(val);
};
@@ -338,6 +358,33 @@ function normalizeStyle(value) {
return normalizeStyle$1(value);
}
}
function normalizeClass(value) {
let res = "";
const g2 = getGlobal$1();
if (g2 && g2.UTSJSONObject && value instanceof g2.UTSJSONObject) {
g2.UTSJSONObject.keys(value).forEach((key) => {
if (value[key]) {
res += key + " ";
}
});
} else if (value instanceof Map) {
value.forEach((value2, key) => {
if (value2) {
res += key + " ";
}
});
} else if (isArray(value)) {
for (let i = 0; i < value.length; i++) {
const normalized = normalizeClass(value[i]);
if (normalized) {
res += normalized + " ";
}
}
} else {
res = normalizeClass$1(value);
}
return res.trim();
}
const encode = encodeURIComponent;
function stringifyQuery(obj, encodeStr = encode) {
const res = obj ? Object.keys(obj).map((key) => {
@@ -5855,6 +5902,7 @@ function genUniElementId(_ctx, idBinding, genId) {
const o = (value, key) => vOn(value, key);
const f = (source, renderItem) => vFor(source, renderItem);
const e = (target, ...sources) => extend(target, ...sources);
const n = (value) => normalizeClass(value);
const t = (val) => toDisplayString(val);
const p = (props) => renderProps(props);
const sei = setUniElementId;
@@ -6529,8 +6577,8 @@ const $once = defineSyncApi(API_ONCE, (name, callback) => {
const $off = defineSyncApi(API_OFF, (name, callback) => {
if (!isArray(name))
name = name ? [name] : [];
name.forEach((n) => {
eventBus.off(n, callback);
name.forEach((n2) => {
eventBus.off(n2, callback);
});
}, OffProtocol);
const $emit = defineSyncApi(API_EMIT, (name, ...args) => {
@@ -7848,7 +7896,7 @@ function isConsoleWritable() {
function initRuntimeSocketService() {
const hosts = "192.168.25.30,172.25.240.1,192.168.1.43,127.0.0.1";
const port = "8090";
const id = "mp-weixin_8xzhU8";
const id = "mp-weixin_IIWuS0";
const lazy = typeof swan !== "undefined";
let restoreError = lazy ? () => {
} : initOnError();
@@ -9550,6 +9598,7 @@ exports.e = e;
exports.f = f;
exports.gei = gei;
exports.index = index;
exports.n = n;
exports.o = o;
exports.onLoad = onLoad;
exports.onMounted = onMounted;