Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@opentiny/vue-checkbox

Package Overview
Dependencies
Maintainers
1
Versions
63
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@opentiny/vue-checkbox - npm Package Compare versions

Comparing version 3.9.0 to 3.10.0

__tests__/checkbox.test.d.ts

2

lib/index.js

@@ -88,3 +88,3 @@ function _extends() {

});
var version = "3.9.0";
var version = "3.10.0";
Checkbox.model = {

@@ -91,0 +91,0 @@ prop: "modelValue",

import { renderless, api } from "@opentiny/vue-renderless/checkbox/vue";
import { defineComponent, props, setup as _setup } from "@opentiny/vue-common";
import { iconHalfselect, iconCheckedSur, iconCheck } from "@opentiny/vue-icon";
import { resolveComponent, openBlock, createElementBlock, mergeProps, createElementVNode, normalizeClass, createBlock, createCommentVNode, withDirectives, withModifiers, vModelCheckbox, renderSlot, createTextVNode, toDisplayString } from "vue";
import { resolveComponent, openBlock, createElementBlock, mergeProps, createElementVNode, normalizeClass, createBlock, createCommentVNode, withDirectives, withModifiers, vModelCheckbox, renderSlot, createTextVNode, toDisplayString, Fragment } from "vue";
function _createForOfIteratorHelperLoose(o, allowArrayLike) {

@@ -53,3 +53,3 @@ var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"];

emits: ["update:modelValue", "change", "complete"],
props: [].concat(props, ["modelValue", "text", "events", "label", "indeterminate", "disabled", "checked", "name", "trueLabel", "falseLabel", "id", "controls", "size", "border", "validateEvent", "customClass"]),
props: [].concat(props, ["modelValue", "text", "events", "label", "indeterminate", "disabled", "checked", "name", "trueLabel", "falseLabel", "id", "controls", "size", "border", "validateEvent", "customClass", "displayOnly"]),
components: {

@@ -77,2 +77,6 @@ IconHalfselect: iconHalfselect(),

var _hoisted_5 = ["aria-hidden", "disabled", "value", "name"];
var _hoisted_6 = {
key: 0,
class: "text-color-text-primary cursor-default"
};
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {

@@ -86,7 +90,7 @@ var _component_icon_check = resolveComponent("icon-check");

"sm:py-2": _ctx.state.vertical
}, _ctx.customClass),
}, _ctx.state.isDisplayOnly || _ctx.state.isGroupDisplayOnly ? _ctx.state.isChecked ? "cursor-default after:content-[';'] after:inline-block last:after:content-['']" : "hidden" : "", _ctx.state.showLabel ? "inline-flex" : "", _ctx.customClass),
id: _ctx.id,
tabindex: "-1"
}, _ctx.a(_ctx.$attrs, ["class", "style", "onClick"], true)), [createElementVNode("span", {
class: normalizeClass(["relative", _ctx.state.size === "medium" ? "sm:w-6 sm:h-6" : "sm:h-4 sm:w-4"]),
class: normalizeClass(["relative", _ctx.state.size === "medium" ? "sm:w-6 sm:h-6" : "sm:h-4 sm:w-4", _ctx.state.isDisplayOnly || _ctx.state.isGroupDisplayOnly ? "hidden" : ""]),
role: _ctx.indeterminate ? "checkbox" : false,

@@ -114,3 +118,3 @@ "aria-checked": _ctx.indeterminate ? "mixed" : false

name: _ctx.name,
disabled: _ctx.state.isDisabled,
disabled: _ctx.state.inputDisabled,
"true-value": _ctx.trueLabel,

@@ -137,3 +141,3 @@ "false-value": _ctx.falseLabel,

"aria-hidden": _ctx.indeterminate ? "true" : "false",
disabled: _ctx.state.isDisabled,
disabled: _ctx.state.inputDisabled,
value: _ctx.label,

@@ -155,3 +159,3 @@ name: _ctx.name,

}, ["stop"]))
}, null, 40, _hoisted_5)), [[vModelCheckbox, _ctx.state.model]])], 10, _hoisted_2), _ctx.slots.default && _ctx.slots.default() || _ctx.text || _ctx.label ? (openBlock(), createElementBlock(
}, null, 40, _hoisted_5)), [[vModelCheckbox, _ctx.state.model]])], 10, _hoisted_2), _ctx.slots.default && _ctx.slots.default() || _ctx.state.isShowText ? (openBlock(), createElementBlock(
"span",

@@ -161,7 +165,7 @@ {

ref: "label",
class: normalizeClass(["py-3 sm:py-0 pl-0 sm:pl-2 mr-5 flex-auto", _ctx.state.isDisabled ? "cursor-not-allowed text-color-text-disabled" : "text-color-text-primary"])
class: normalizeClass(_ctx.m("py-3 sm:py-0 pl-0 sm:pl-2 mr-5 flex-auto", _ctx.state.isDisabled ? "cursor-not-allowed text-color-text-disabled" : "text-color-text-primary", _ctx.state.isDisplayOnly || _ctx.state.isGroupDisplayOnly ? "p-0 sm:p-0 m-0 text-color-text-primary cursor-default" : ""))
},
[renderSlot(_ctx.$slots, "default", {}, function() {
return [createTextVNode(
toDisplayString(_ctx.text || _ctx.label),
toDisplayString(_ctx.state.showText),
1

@@ -173,3 +177,17 @@ /* TEXT */

/* CLASS */
)) : createCommentVNode("v-if", true)], 16, _hoisted_1);
)) : (openBlock(), createElementBlock(
Fragment,
{
key: 1
},
[_ctx.state.isDisplayOnly ? (openBlock(), createElementBlock(
"span",
_hoisted_6,
toDisplayString(_ctx.state.displayLabel),
1
/* TEXT */
)) : createCommentVNode("v-if", true)],
64
/* STABLE_FRAGMENT */
))], 16, _hoisted_1);
}

@@ -176,0 +194,0 @@ var mobileFirst = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);

@@ -134,5 +134,5 @@ import { renderless, api } from "@opentiny/vue-renderless/checkbox/vue";

})
}, null, 40, _hoisted_5)), [[vModelCheckbox, _ctx.state.model]])], 8, _hoisted_2), _ctx.slots.default && _ctx.slots.default() || _ctx.text || _ctx.label ? (openBlock(), createElementBlock("span", _hoisted_6, [renderSlot(_ctx.$slots, "default", {}, function() {
}, null, 40, _hoisted_5)), [[vModelCheckbox, _ctx.state.model]])], 8, _hoisted_2), _ctx.slots.default && _ctx.slots.default() || _ctx.state.isShowText ? (openBlock(), createElementBlock("span", _hoisted_6, [renderSlot(_ctx.$slots, "default", {}, function() {
return [createTextVNode(
toDisplayString(_ctx.text || _ctx.label),
toDisplayString(_ctx.state.showText),
1

@@ -139,0 +139,0 @@ /* TEXT */

@@ -86,3 +86,3 @@ import { renderless, api } from "@opentiny/vue-renderless/checkbox/vue";

class: ["tiny-checkbox", [_ctx.border && _ctx.state.checkboxSize ? "tiny-checkbox--" + _ctx.state.checkboxSize : "", {
"is-disabled": _ctx.state.isDisabled
"is-disabled": _ctx.state.isDisabled || _ctx.state.isDisplayOnly
}, {

@@ -101,3 +101,3 @@ "is-bordered": _ctx.border

class: normalizeClass(["tiny-checkbox__input", {
"is-disabled": _ctx.state.isDisabled,
"is-disabled": _ctx.state.isDisabled || _ctx.state.isDisplayOnly,
"is-checked": _ctx.state.isChecked,

@@ -124,3 +124,3 @@ "is-indeterminate": _ctx.indeterminate,

name: _ctx.name,
disabled: _ctx.state.isDisabled,
disabled: _ctx.state.isDisabled || _ctx.state.isDisplayOnly,
"true-value": _ctx.trueLabel,

@@ -147,3 +147,3 @@ "false-value": _ctx.falseLabel,

"aria-hidden": _ctx.indeterminate ? "true" : "false",
disabled: _ctx.state.isDisabled,
disabled: _ctx.state.isDisabled || _ctx.state.isDisplayOnly,
value: _ctx.label,

@@ -165,5 +165,5 @@ name: _ctx.name,

}, ["stop"]))
}, null, 40, _hoisted_5)), [[vModelCheckbox, _ctx.state.model]])], 10, _hoisted_2), _ctx.slots.default && _ctx.slots.default() || _ctx.text || _ctx.label ? (openBlock(), createElementBlock("span", _hoisted_6, [renderSlot(_ctx.$slots, "default", {}, function() {
}, null, 40, _hoisted_5)), [[vModelCheckbox, _ctx.state.model]])], 10, _hoisted_2), _ctx.slots.default && _ctx.slots.default() || _ctx.state.isShowText ? (openBlock(), createElementBlock("span", _hoisted_6, [renderSlot(_ctx.$slots, "default", {}, function() {
return [createTextVNode(
toDisplayString(_ctx.text || _ctx.label),
toDisplayString(_ctx.state.showText),
1

@@ -170,0 +170,0 @@ /* TEXT */

{
"name": "@opentiny/vue-checkbox",
"version": "3.9.0",
"version": "3.10.0",
"description": "",

@@ -8,5 +8,6 @@ "main": "./lib/index.js",

"sideEffects": false,
"type": "module",
"dependencies": {
"@opentiny/vue-common": "~3.9.0",
"@opentiny/vue-renderless": "~3.9.0"
"@opentiny/vue-common": "~3.10.0",
"@opentiny/vue-renderless": "~3.10.0"
},

@@ -13,0 +14,0 @@ "license": "MIT",

@@ -17,4 +17,4 @@ declare const _default: import("@vue/runtime-core").DefineComponent<{

name: StringConstructor;
trueLabel: (NumberConstructor | StringConstructor)[];
falseLabel: (NumberConstructor | StringConstructor)[];
trueLabel: (StringConstructor | NumberConstructor)[];
falseLabel: (StringConstructor | NumberConstructor)[];
id: StringConstructor;

@@ -43,5 +43,5 @@ controls: StringConstructor;

tiny_chart_theme: ObjectConstructor;
}, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
}, () => import("@vue/runtime-core").VNode<import("@vue/runtime-core").RendererNode, import("@vue/runtime-core").RendererElement, {
[key: string]: any;
}>, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("@vue/runtime-core").ExtractPropTypes<{
}>, unknown, {}, {}, import("@vue/runtime-core").ComponentOptionsMixin, import("@vue/runtime-core").ComponentOptionsMixin, {}, string, import("@vue/runtime-core").VNodeProps & import("@vue/runtime-core").AllowedComponentProps & import("@vue/runtime-core").ComponentCustomProps, Readonly<import("@vue/runtime-core").ExtractPropTypes<{
_constants: {

@@ -62,4 +62,4 @@ type: ObjectConstructor;

name: StringConstructor;
trueLabel: (NumberConstructor | StringConstructor)[];
falseLabel: (NumberConstructor | StringConstructor)[];
trueLabel: (StringConstructor | NumberConstructor)[];
falseLabel: (StringConstructor | NumberConstructor)[];
id: StringConstructor;

@@ -89,12 +89,12 @@ controls: StringConstructor;

}>>, {
disabled: boolean;
tiny_mode_root: boolean;
_constants: Record<string, any>;
disabled: boolean;
border: boolean;
validateEvent: boolean;
displayOnly: boolean;
events: Record<string, any>;
border: boolean;
checked: boolean;
indeterminate: boolean;
checked: boolean;
validateEvent: boolean;
}>;
}, {}>;
export default _default;

@@ -1,4 +0,4 @@

declare const _sfc_main: import("@vue/runtime-core").DefineComponent<Readonly<{
declare const _default: import("@vue/runtime-core").DefineComponent<Readonly<{
[x: string]: any;
}>, any, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "change" | "complete")[], "update:modelValue" | "change" | "complete", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("@vue/runtime-core").ExtractPropTypes<Readonly<{
}>, any, unknown, {}, {}, import("@vue/runtime-core").ComponentOptionsMixin, import("@vue/runtime-core").ComponentOptionsMixin, ("update:modelValue" | "change" | "complete")[], "update:modelValue" | "change" | "complete", import("@vue/runtime-core").VNodeProps & import("@vue/runtime-core").AllowedComponentProps & import("@vue/runtime-core").ComponentCustomProps, Readonly<import("@vue/runtime-core").ExtractPropTypes<Readonly<{
[x: string]: any;

@@ -11,3 +11,3 @@ }>>> & {

[x: string]: any;
}>;
export default _sfc_main;
}, {}>;
export default _default;

@@ -1,2 +0,2 @@

declare const _sfc_main: import("@vue/runtime-core").DefineComponent<Readonly<{
declare const _default: import("@vue/runtime-core").DefineComponent<Readonly<{
[x: string]: any;

@@ -12,7 +12,7 @@ }>, {

m: (...cssClasses: any[]) => string;
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("@vue/runtime-core").ExtractPropTypes<Readonly<{
}, unknown, {}, {}, import("@vue/runtime-core").ComponentOptionsMixin, import("@vue/runtime-core").ComponentOptionsMixin, {}, string, import("@vue/runtime-core").VNodeProps & import("@vue/runtime-core").AllowedComponentProps & import("@vue/runtime-core").ComponentCustomProps, Readonly<import("@vue/runtime-core").ExtractPropTypes<Readonly<{
[x: string]: any;
}>>>, {
[x: string]: any;
}>;
export default _sfc_main;
}, {}>;
export default _default;

@@ -1,2 +0,2 @@

declare const _sfc_main: import("@vue/runtime-core").DefineComponent<Readonly<{
declare const _default: import("@vue/runtime-core").DefineComponent<Readonly<{
[x: string]: any;

@@ -12,3 +12,3 @@ }>, {

m: (...cssClasses: any[]) => string;
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "change" | "complete")[], "update:modelValue" | "change" | "complete", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("@vue/runtime-core").ExtractPropTypes<Readonly<{
}, unknown, {}, {}, import("@vue/runtime-core").ComponentOptionsMixin, import("@vue/runtime-core").ComponentOptionsMixin, ("update:modelValue" | "change" | "complete")[], "update:modelValue" | "change" | "complete", import("@vue/runtime-core").VNodeProps & import("@vue/runtime-core").AllowedComponentProps & import("@vue/runtime-core").ComponentCustomProps, Readonly<import("@vue/runtime-core").ExtractPropTypes<Readonly<{
[x: string]: any;

@@ -21,3 +21,3 @@ }>>> & {

[x: string]: any;
}>;
export default _sfc_main;
}, {}>;
export default _default;
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc