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

@umbraco-ui/uui-boolean-input

Package Overview
Dependencies
Maintainers
5
Versions
50
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@umbraco-ui/uui-boolean-input - npm Package Compare versions

Comparing version 1.0.0-rc.1 to 1.0.0-rc.2

21

lib/index.js

@@ -21,3 +21,5 @@ import { FormControlMixin, LabelMixin } from '@umbraco-ui/uui-base/lib/mixins';

};
class UUIBooleanInputElement extends FormControlMixin(LabelMixin("", LitElement)) {
class UUIBooleanInputElement extends FormControlMixin(
LabelMixin("", LitElement)
) {
constructor(inputRole = "checkbox") {

@@ -32,2 +34,3 @@ super();

this.inputRole = inputRole;
this.addEventListener("keypress", this._onKeypress);
}

@@ -41,3 +44,5 @@ get value() {

if ("ElementInternals" in window && "setFormValue" in window.ElementInternals.prototype) {
this._internals.setFormValue(this._checked && this.name !== "" ? this._value : null);
this._internals.setFormValue(
this._checked && this.name !== "" ? this._value : null
);
}

@@ -52,3 +57,5 @@ this.requestUpdate("value", oldValue);

this._checked = newVal;
this._internals.setFormValue(this._checked && this.name !== "" ? this._value ? this._value : "on" : null);
this._internals.setFormValue(
this._checked && this.name !== "" ? this._value ? this._value : "on" : null
);
this.requestUpdate("checked", oldValue);

@@ -59,2 +66,7 @@ }

}
_onKeypress(e) {
if (e.key == "Enter") {
this.submit();
}
}
hasValue() {

@@ -92,3 +104,4 @@ return this.checked;

}
_onInputChange() {
_onInputChange(e) {
e.stopPropagation();
this.pristine = false;

@@ -95,0 +108,0 @@ this.checked = this._input.checked;

@@ -43,2 +43,3 @@ import { LitElement, TemplateResult } from 'lit';

protected getFormElement(): HTMLElement;
private _onKeypress;
hasValue(): boolean;

@@ -45,0 +46,0 @@ formResetCallback(): void;

6

package.json
{
"name": "@umbraco-ui/uui-boolean-input",
"version": "1.0.0-rc.1",
"version": "1.0.0-rc.2",
"license": "MIT",

@@ -33,3 +33,3 @@ "keywords": [

"dependencies": {
"@umbraco-ui/uui-base": "1.0.0-rc.1"
"@umbraco-ui/uui-base": "1.0.0-rc.2"
},

@@ -45,3 +45,3 @@ "scripts": {

"homepage": "https://uui.umbraco.com/?path=/story/uui-boolean-input",
"gitHead": "127e036dbafa18cc37027591d6548a4cb4700d33"
"gitHead": "436dd8d9fff81481feb88f06b461167c98dac91a"
}
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