Socket
Socket
Sign inDemoInstall

ya-input

Package Overview
Dependencies
Maintainers
2
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ya-input - npm Package Compare versions

Comparing version 0.1.3 to 0.1.4

12

addon/components/ya-input/component.js

@@ -28,3 +28,2 @@ import Ember from 'ember';

hasLostFocus: false,
hasInitialFocus: false,

@@ -84,5 +83,5 @@ wrapped: oneWay('form.wrapped'),

validClass: computed('errors.[]', 'field-name', 'canShowErrors', 'errorText', 'hasFocusedOnce', 'shouldShowValidationErrors', {
validClass: computed('errors.[]', 'model.errors', 'field-name', 'canShowErrors', 'errorText', 'hasFocusedOnce', 'shouldShowValidationErrors', {
get() {
return this._getValidClass(get(this, 'model.errors'), get(this, 'field-name'));
return this._getValidClass(get(this, 'errors.length'), get(this, 'model.errors'), get(this, 'field-name'));
}

@@ -93,3 +92,2 @@ }),

set(this, 'hasLostFocus', false);
set(this, 'hasInitialFocus', true);
},

@@ -110,3 +108,3 @@

*/
_getValidClass(modelErrors, fieldName) {
_getValidClass(errorsCount, modelErrors, fieldName) {
if (get(this, 'hasFocusedOnce') || get(this, 'shouldShowValidationErrors')) {

@@ -117,4 +115,6 @@ if (this._hasDSError(modelErrors, fieldName)) {

return get(this, 'canShowErrors') ? 'is-invalid' : 'is-valid';
return (get(this, 'canShowErrors') || errorsCount > 0) ? 'is-invalid' : 'is-valid';
}
return;
},

@@ -121,0 +121,0 @@

{
"name": "ya-input",
"version": "0.1.3",
"version": "0.1.4",
"description": "The default blueprint for ember-cli addons.",

@@ -5,0 +5,0 @@ "directories": {

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