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

terra-toggle

Package Overview
Dependencies
Maintainers
9
Versions
126
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

terra-toggle - npm Package Compare versions

Comparing version 3.44.0 to 3.45.0

11

CHANGELOG.md

@@ -5,2 +5,9 @@ # Changelog

## 3.45.0 - (April 6, 2021)
* Changed
* Removed unnecessary `wdio.conf.js` file
* Upgrade tests to terra-functional-testing and WebDriverIO v6
* Updated Jest command
## 3.44.0 - (February 2, 2021)

@@ -14,4 +21,4 @@

* Fixed
* Fixed broken links in documentation.
* Fixed broken links in documentation.
## 3.42.0 - (December 8, 2020)

@@ -18,0 +25,0 @@

14

package.json
{
"name": "terra-toggle",
"main": "lib/Toggle.js",
"version": "3.44.0",
"version": "3.45.0",
"description": "Toggle component that transitions content in and out.",

@@ -32,3 +32,3 @@ "repository": {

"react-animate-height": "^2.0.1",
"terra-icon": "^3.41.0"
"terra-icon": "^3.42.0"
},

@@ -42,9 +42,9 @@ "scripts": {

"test": "npm run lint && npm run jest && npm run wdio",
"jest": "jest --config ../../jestconfig.js",
"wdio-default": "cd ../.. && npx wdio",
"wdio-lowlight": "cd ../.. && THEME=clinical-lowlight-theme npx wdio",
"wdio-fusion": "cd ../.. && THEME=orion-fusion-theme npx wdio",
"jest": "jest --config ../../jest.config.js",
"wdio-default": "cd ../.. && terra wdio",
"wdio-lowlight": "cd ../.. && terra wdio --themes clinical-lowlight-theme",
"wdio-fusion": "cd ../.. && terra wdio --themes orion-fusion-theme",
"wdio": "npm run wdio-default && npm run wdio-lowlight && npm run wdio-fusion"
},
"gitHead": "f34a76024b33d4b2f25492c5983f3b73a27c107e"
"gitHead": "b6ddb01d67dc1ecbe6fd0eba0ddc8f46b7eb3d61"
}
Terra.describeViewports('Toggle', ['medium'], () => {
describe('Default', () => {
it('displays a closed toggle', () => {
browser.url('/raw/tests/terra-toggle/toggle/default-toggle');
Terra.validates.element('closed');
});
it('should expand the toggle', () => {
browser.url('/raw/tests/terra-toggle/toggle/default-toggle');
$('#trigger-toggle').click();
Terra.validates.element('expanded toggle');
});
it('expands', () => {
browser.click('#trigger-toggle'); // Open toggle
Terra.validates.element('expanded');
});
it('should display a closed toggle', () => {
$('#trigger-toggle').click();
Terra.validates.element('closed toggle');
});
it('displays an opened toggle', () => {
it('should display an opened toggle', () => {
browser.url('/raw/tests/terra-toggle/toggle/open-toggle');
browser.moveToObject('#root', 0, 0);
Terra.validates.element('opened');
$('#root').moveTo({ xOffset: 0, yOffset: 0 });
Terra.validates.element('opened toggle');
});
describe('Animated', () => {
it('disables focusable elements when closed', () => {
browser.url('/raw/tests/terra-toggle/toggle/animated-toggle');
expect(browser.getCssProperty('#toggle', 'visibility').value).to.equal('hidden');
});
it('should disable focusable elements when closed', () => {
browser.url('/raw/tests/terra-toggle/toggle/animated-toggle');
expect($('#toggle').getCSSProperty('visibility').value).toBe('hidden');
});
it('enables focusable elements when opened', () => {
browser.click('#trigger-toggle'); // Open toggle
browser.waitForVisible('#toggle');
expect(browser.getCssProperty('#toggle', 'visibility').value).to.equal('visible');
});
it('should enable focusable elements when opened', () => {
$('#trigger-toggle').click();
const element = $('#toggle');
element.waitForDisplayed();
expect(element.getCSSProperty('visibility').value).toBe('visible');
});
});
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