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

@mcwv/textfield

Package Overview
Dependencies
Maintainers
1
Versions
35
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@mcwv/textfield - npm Package Compare versions

Comparing version 0.14.0 to 0.15.0

18

package.json
{
"name": "@mcwv/textfield",
"description": "The Vue Material Adapter for the web textfield component",
"version": "0.14.0",
"version": "0.15.0",
"license": "MIT",

@@ -19,11 +19,11 @@ "main": "dist/mcwv.textfield.min.js",

"dependencies": {
"@material/dom": "^4.0.0",
"@material/textfield": "^4.0.0",
"@mcwv/base": "^0.14.0",
"@mcwv/floating-label": "^0.14.0",
"@mcwv/line-ripple": "^0.14.0",
"@mcwv/notched-outline": "^0.14.0",
"@mcwv/ripple": "^0.14.0"
"@material/dom": "^5.1.0",
"@material/textfield": "^5.1.0",
"@mcwv/base": "^0.15.0",
"@mcwv/floating-label": "^0.15.0",
"@mcwv/line-ripple": "^0.15.0",
"@mcwv/notched-outline": "^0.15.0",
"@mcwv/ripple": "^0.15.0"
},
"gitHead": "78fd659b77df5ddf640cacf3c86edd798f679972"
"gitHead": "b22bec8a9ecd8b859f8435c2fd5ef3865ba22f64"
}

@@ -11,2 +11,3 @@ /* eslint-disable quote-props */

import TextfieldIcon from './textfield-icon.js';
import { matches } from '@material/dom/ponyfill';

@@ -61,3 +62,3 @@ export default {

text: this.value,
rootClasses: {
classes: {
'mdc-textfield': true,

@@ -76,2 +77,3 @@ 'mdc-text-field': true,

},
styles: {},
inputClasses: {

@@ -133,3 +135,3 @@ 'mdc-text-field__input': true,

dense() {
this.$set(this.rootClasses, 'mdc-text-field--dense', this.dense);
this.$set(this.classes, 'mdc-text-field--dense', this.dense);
},

@@ -149,6 +151,6 @@ value(value) {

addClass: className => {
this.$set(this.rootClasses, className, true);
this.$set(this.classes, className, true);
},
removeClass: className => {
this.$delete(this.rootClasses, className);
this.$delete(this.classes, className);
},

@@ -208,4 +210,22 @@ hasClass: className => {

if (this.textbox) {
this.ripple = new RippleBase(this);
const isTextArea = this.$refs.root.classList.contains(
'mdc-text-field--textarea',
);
const isOutlined = this.$refs.root.classList.contains(
'mdc-text-field--outlined',
);
if (!isTextArea && !isOutlined) {
this.ripple = new RippleBase(this, {
isSurfaceActive: () => matches(this.$refs.input, ':active'),
registerInteractionHandler: (evtType, handler) => {
this.$refs.input.addEventListener(evtType, handler, applyPassive());
},
deregisterInteractionHandler: (evtType, handler) =>
this.$refs.input.removeEventListener(
evtType,
handler,
applyPassive(),
),
});
this.ripple.init();

@@ -330,2 +350,9 @@ }

rootNodes.push(
createElement('span', {
class: 'mdc-text-field__ripple',
ref: 'ripple',
}),
);
rootNodes.push(
createElement('input', {

@@ -342,2 +369,3 @@ class: this.inputClasses,

'aria-controls': this.inputAriaControls,
'aria-labelledby': `label-${this.vma_uid_}`,
},

@@ -358,3 +386,3 @@ ref: 'input',

{
attrs: { for: this.vma_uid_ },
attrs: { id: `label-${this.vma_uid_}` },
ref: 'labelEl',

@@ -401,5 +429,6 @@ },

const rootEl = createElement(
'div',
'label',
{
class: this.rootClasses,
class: this.classes,
style: this.styles,
ref: 'root',

@@ -406,0 +435,0 @@ },

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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

Sorry, the diff of this file is not supported yet

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