New:Socket for Asana Is Now Available.Learn more
Get Started

@vue/runtime-dom

Package Overview
Dependencies
Maintainers
1
Versions
297
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@vue/runtime-dom - npm Package Compare versions

Comparing version
3.5.41
to
3.5.42
+36
-10
dist/runtime-dom.cjs.js
/**
* @vue/runtime-dom v3.5.41
* @vue/runtime-dom v3.5.42
* (c) 2018-present Yuxi (Evan) You and Vue contributors

@@ -520,3 +520,7 @@ * @license MIT

if (name.startsWith("--")) {
style.setProperty(name, val);
if (importantRE.test(val)) {
style.setProperty(name, val.replace(importantRE, ""), "important");
} else {
style.setProperty(name, val);
}
} else {

@@ -1655,9 +1659,17 @@ const prefixed = autoPrefix(style, name);

);
el[assignKey](
el.multiple ? shared.isSet(el._modelValue) ? new Set(selectedVal) : selectedVal : selectedVal[0]
);
el._assigning = true;
runtimeCore.nextTick(() => {
el._assigning = false;
});
const multiple = el.multiple;
const assignedValue = multiple ? shared.isSet(el._modelValue) ? new Set(selectedVal) : selectedVal : selectedVal[0];
const pending = el._pendingValue = [
multiple,
multiple ? shared.isArray(assignedValue) ? selectedVal.slice() : selectedVal : assignedValue
];
try {
el[assignKey](assignedValue);
} finally {
runtimeCore.nextTick(() => {
if (el._pendingValue === pending) {
el._pendingValue = void 0;
}
});
}
});

@@ -1676,3 +1688,5 @@ el[assignKey] = getModelAssigner(vnode);

updated(el, { value }) {
if (!el._assigning) {
const pending = el._pendingValue;
el._pendingValue = void 0;
if (!pending || pending[0] !== el.multiple || !isSameSelectValue(value, pending[1], pending[0])) {
setSelected(el, value);

@@ -1682,2 +1696,14 @@ }

};
function isSameSelectValue(value, assignedValue, multiple) {
if (!multiple) return shared.looseEqual(value, assignedValue);
if (shared.isArray(value)) return shared.looseEqual(value, assignedValue);
if (shared.isSet(value)) {
if (value.size !== assignedValue.length) return false;
for (const item of assignedValue) {
if (!value.has(item)) return false;
}
return true;
}
return false;
}
function setSelected(el, value) {

@@ -1684,0 +1710,0 @@ const isMultiple = el.multiple;

/**
* @vue/runtime-dom v3.5.41
* @vue/runtime-dom v3.5.42
* (c) 2018-present Yuxi (Evan) You and Vue contributors

@@ -508,3 +508,7 @@ * @license MIT

if (name.startsWith("--")) {
style.setProperty(name, val);
if (importantRE.test(val)) {
style.setProperty(name, val.replace(importantRE, ""), "important");
} else {
style.setProperty(name, val);
}
} else {

@@ -1556,9 +1560,17 @@ const prefixed = autoPrefix(style, name);

);
el[assignKey](
el.multiple ? shared.isSet(el._modelValue) ? new Set(selectedVal) : selectedVal : selectedVal[0]
);
el._assigning = true;
runtimeCore.nextTick(() => {
el._assigning = false;
});
const multiple = el.multiple;
const assignedValue = multiple ? shared.isSet(el._modelValue) ? new Set(selectedVal) : selectedVal : selectedVal[0];
const pending = el._pendingValue = [
multiple,
multiple ? shared.isArray(assignedValue) ? selectedVal.slice() : selectedVal : assignedValue
];
try {
el[assignKey](assignedValue);
} finally {
runtimeCore.nextTick(() => {
if (el._pendingValue === pending) {
el._pendingValue = void 0;
}
});
}
});

@@ -1577,3 +1589,5 @@ el[assignKey] = getModelAssigner(vnode);

updated(el, { value }) {
if (!el._assigning) {
const pending = el._pendingValue;
el._pendingValue = void 0;
if (!pending || pending[0] !== el.multiple || !isSameSelectValue(value, pending[1], pending[0])) {
setSelected(el, value);

@@ -1583,2 +1597,14 @@ }

};
function isSameSelectValue(value, assignedValue, multiple) {
if (!multiple) return shared.looseEqual(value, assignedValue);
if (shared.isArray(value)) return shared.looseEqual(value, assignedValue);
if (shared.isSet(value)) {
if (value.size !== assignedValue.length) return false;
for (const item of assignedValue) {
if (!value.has(item)) return false;
}
return true;
}
return false;
}
function setSelected(el, value) {

@@ -1585,0 +1611,0 @@ const isMultiple = el.multiple;

@@ -87,3 +87,3 @@ import { RendererOptions, BaseTransitionProps, FunctionalComponent, ObjectDirective, Directive, VNodeRef, App, ComponentCustomElementInterface, ConcreteComponent, CreateAppFunction, SetupContext, RenderFunction, ComponentOptions, ComponentObjectPropsOptions, EmitsOptions, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentInjectOptions, SlotsType, Component, ComponentProvideOptions, ExtractPropTypes, EmitsToProps, ComponentOptionsBase, CreateComponentPublicInstanceWithMixins, ComponentPublicInstance, DefineComponent, RootHydrateFunction, RootRenderFunction } from '@vue/runtime-core';

[initialValueKey]?: string;
_assigning?: boolean;
_pendingValue?: [multiple: boolean, value: any];
}, any, Modifiers>;

@@ -90,0 +90,0 @@ export declare const vModelText: ModelDirective<HTMLInputElement | HTMLTextAreaElement, 'trim' | 'number' | 'lazy'>;

{
"name": "@vue/runtime-dom",
"version": "3.5.41",
"version": "3.5.42",
"description": "@vue/runtime-dom",

@@ -53,5 +53,5 @@ "main": "index.js",

"csstype": "^3.2.3",
"@vue/shared": "3.5.41",
"@vue/runtime-core": "3.5.41",
"@vue/reactivity": "3.5.41"
"@vue/shared": "3.5.42",
"@vue/runtime-core": "3.5.42",
"@vue/reactivity": "3.5.42"
},

@@ -58,0 +58,0 @@ "devDependencies": {

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display