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

wvi-test-ui-components

Package Overview
Dependencies
Maintainers
1
Versions
129
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

wvi-test-ui-components - npm Package Compare versions

Comparing version 0.0.95 to 0.0.96

2

package.json
{
"name": "wvi-test-ui-components",
"version": "0.0.95",
"version": "0.0.96",
"description": "React component library for WVI",

@@ -5,0 +5,0 @@ "main": "src/dist/ui.js",

@@ -9,10 +9,2 @@ import React from 'react';

/**
* Handles the action.
*/
const handleAction = () => {
const { action } = props;
action();
}
// Create a Button component that will render a <button> element with styles.

@@ -50,5 +42,5 @@ const Button = styled.button`

return (
<Button onClick={() => handleAction()}>
{props.text}
</Button>
<Button
onClick={props.action}
>{props.text}</Button>
);

@@ -55,0 +47,0 @@ }

@@ -7,3 +7,2 @@ import React from 'react';

import LinkButton from '../Button/LinkButton';
import ActionButton from '../Button/ActionButton';
import Icon from '../Icon';

@@ -68,11 +67,6 @@ import Image from '../Image';

renderButton() {
renderLinkButton() {
const button = this.props.data.button;
if (button !== undefined) {
return <LinkButton text={button.text} link={button.link}/>;
// return (
// (button.action !== undefined) ?
// <ActionButton text={button.text} action={button.action}/> :
// <LinkButton text={button.text} link={button.link}/>
// );
}

@@ -237,3 +231,3 @@ }

{this.renderFormFields()}
{this.renderButton()}
{this.renderLinkButton()}
</div>

@@ -240,0 +234,0 @@ </ItemBox>

@@ -139,4 +139,4 @@

button: {
text: 'Search',
action: () => handleSearch(),
text: 'Click here',
link: '#',
}

@@ -243,3 +243,3 @@ };

// Dummy functions that need to be passed to the components.
// Dummy functions that need to be passed to the child component.
function handleFieldChange(name, value) {

@@ -251,4 +251,3 @@ console.log('handle field change', name, value);

}
function handleSearch() {
console.log('handle search');
}

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

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