讨论加特殊图标

This commit is contained in:
DESKTOP-RQ919RC\Pc
2025-03-21 15:49:12 +08:00
parent 0ed747a035
commit dd619643c9
202 changed files with 2973 additions and 2866 deletions

View File

@@ -1,3 +1,8 @@
/**
* @vue/runtime-dom v3.4.15
* (c) 2018-present Yuxi (Evan) You and Vue contributors
* @license MIT
**/
'use strict';
Object.defineProperty(exports, '__esModule', { value: true });
@@ -407,6 +412,7 @@ function useCssVars(getter) {
function patchStyle(el, prev, next) {
const style = el.style;
const currentDisplay = style.display;
const isCssString = shared.isString(next);
if (next && !isCssString) {
if (prev && !shared.isString(prev)) {
@@ -420,7 +426,6 @@ function patchStyle(el, prev, next) {
setStyle(style, key, next[key]);
}
} else {
const currentDisplay = style.display;
if (isCssString) {
if (prev !== next) {
const cssVarText = style[CSS_VAR_TEXT];
@@ -432,9 +437,9 @@ function patchStyle(el, prev, next) {
} else if (prev) {
el.removeAttribute("style");
}
if (vShowOldKey in el) {
style.display = currentDisplay;
}
}
if (vShowOldKey in el) {
style.display = currentDisplay;
}
}
const importantRE = /\s*!important$/;
@@ -1163,32 +1168,49 @@ const vModelSelect = {
el[assignKey](
el.multiple ? isSetModel ? new Set(selectedVal) : selectedVal : selectedVal[0]
);
el._assigning = true;
runtimeCore.nextTick(() => {
el._assigning = false;
});
});
el[assignKey] = getModelAssigner(vnode);
},
// set value in mounted & updated because <select> relies on its children
// <option>s.
mounted(el, { value }) {
setSelected(el, value);
mounted(el, { value, oldValue, modifiers: { number } }) {
setSelected(el, value, oldValue, number);
},
beforeUpdate(el, _binding, vnode) {
el[assignKey] = getModelAssigner(vnode);
},
updated(el, { value }) {
setSelected(el, value);
updated(el, { value, oldValue, modifiers: { number } }) {
if (!el._assigning) {
setSelected(el, value, oldValue, number);
}
}
};
function setSelected(el, value) {
function setSelected(el, value, oldValue, number) {
const isMultiple = el.multiple;
if (isMultiple && !shared.isArray(value) && !shared.isSet(value)) {
const isArrayValue = shared.isArray(value);
if (isMultiple && !isArrayValue && !shared.isSet(value)) {
return;
}
if (isArrayValue && shared.looseEqual(value, oldValue)) {
return;
}
for (let i = 0, l = el.options.length; i < l; i++) {
const option = el.options[i];
const optionValue = getValue(option);
if (isMultiple) {
if (shared.isArray(value)) {
option.selected = shared.looseIndexOf(value, optionValue) > -1;
if (isArrayValue) {
const optionType = typeof optionValue;
if (optionType === "string" || optionType === "number") {
option.selected = value.includes(
number ? shared.looseToNumber(optionValue) : optionValue
);
} else {
option.selected = shared.looseIndexOf(value, optionValue) > -1;
}
} else {
option.selected = value.has(optionValue);
}

View File

@@ -1,6 +1,6 @@
{
"name": "@vue/runtime-dom",
"version": "3.4.5",
"version": "3.4.15",
"description": "@vue/runtime-dom",
"main": "index.js",
"module": "dist/runtime-dom.esm-bundler.js",
@@ -18,6 +18,7 @@
"development": "./dist/runtime-dom.cjs.js",
"default": "./dist/runtime-dom.cjs.prod.js"
},
"module": "./dist/runtime-dom.esm-bundler.js",
"import": "./dist/runtime-dom.esm-bundler.js",
"require": "./index.js"
},
@@ -49,7 +50,7 @@
"homepage": "https://github.com/vuejs/core/tree/main/packages/runtime-dom#readme",
"dependencies": {
"csstype": "^3.1.3",
"@vue/shared": "3.4.5",
"@vue/runtime-core": "3.4.5"
"@vue/shared": "3.4.15",
"@vue/runtime-core": "3.4.15"
}
}