New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@stylable/dom-test-kit

Package Overview
Dependencies
Maintainers
7
Versions
220
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@stylable/dom-test-kit - npm Package Compare versions

Comparing version 4.13.2 to 5.0.0-rc.1

16

dist/stylable-dom-util.js
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.StylableDOMUtil = void 0;
const core_1 = require("@stylable/core");
const index_internal_1 = require("@stylable/core/dist/index-internal");
const css_selector_parser_1 = require("@tokey/css-selector-parser");

@@ -42,7 +42,7 @@ function convertToClass(node) {

if (!args) {
convertToClass(node).value = core_1.pseudoStates.createBooleanStateClassName(node.value, namespace);
convertToClass(node).value = index_internal_1.pseudoStates.createBooleanStateClassName(node.value, namespace);
}
else {
const nestedContent = (0, css_selector_parser_1.stringifySelectorAst)(args);
convertToClass(node).value = core_1.pseudoStates.createStateWithParamClassName(node.value, namespace, nestedContent);
convertToClass(node).value = index_internal_1.pseudoStates.createStateWithParamClassName(node.value, namespace, nestedContent);
}

@@ -59,5 +59,5 @@ }

if (typeof param === 'boolean') {
return element.classList.contains(core_1.pseudoStates.createBooleanStateClassName(stateName, namespace));
return element.classList.contains(index_internal_1.pseudoStates.createBooleanStateClassName(stateName, namespace));
}
return element.classList.contains(core_1.pseudoStates.createStateWithParamClassName(stateName, namespace, String(param)));
return element.classList.contains(index_internal_1.pseudoStates.createStateWithParamClassName(stateName, namespace, String(param)));
}

@@ -68,3 +68,3 @@ getStyleState(element, stateName) {

}
const booleanState = core_1.pseudoStates.createBooleanStateClassName(stateName, this.stylesheet.namespace);
const booleanState = index_internal_1.pseudoStates.createBooleanStateClassName(stateName, this.stylesheet.namespace);
if (element.classList.contains(booleanState)) {

@@ -85,3 +85,3 @@ return true;

const param = cls.slice(baseState.length);
const paramIndex = param.indexOf(core_1.pseudoStates.stateMiddleDelimiter);
const paramIndex = param.indexOf(index_internal_1.pseudoStates.stateMiddleDelimiter);
if (paramIndex !== -1) {

@@ -95,3 +95,3 @@ return param.slice(paramIndex + 1);

const singleCharState = 'x';
return core_1.pseudoStates
return index_internal_1.pseudoStates
.createStateWithParamClassName(stateName, this.stylesheet.namespace, singleCharState)

@@ -98,0 +98,0 @@ .slice(0, -3);

{
"name": "@stylable/dom-test-kit",
"version": "4.13.2",
"version": "5.0.0-rc.1",
"description": "Stylable DOM testing utilities",

@@ -11,4 +11,4 @@ "main": "dist/index.js",

"dependencies": {
"@stylable/core": "^4.13.2",
"@stylable/runtime": "^4.13.2",
"@stylable/core": "^v5.0.0-rc.1",
"@stylable/runtime": "^v5.0.0-rc.1",
"@tokey/css-selector-parser": "^0.6.0"

@@ -23,3 +23,3 @@ },

"engines": {
"node": ">=12"
"node": ">=14.14.0"
},

@@ -26,0 +26,0 @@ "publishConfig": {

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

import { pseudoStates } from '@stylable/core';
import { pseudoStates } from '@stylable/core/dist/index-internal';
import {

@@ -3,0 +3,0 @@ parseCssSelector,

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