Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
abaabil.dialog
Advanced tools
The Dialog
component is a versatile and customizable modal dialog built with React. It supports different variants, sizes, and provides accessibility features, making it suitable for a wide range of use cases.
import * as React from 'react';
import Dialog from 'abaabil.dialog';
import Button from 'abaabil.button';
const App = () => {
const [isOpen, setIsOpen] = React.useState(false);
const openDialog = () => setIsOpen(true);
const closeDialog = () => setIsOpen(false);
return (
<div>
<Button onClick={openDialog}>Open Dialog</Button>
<Dialog
isOpen={isOpen}
onClose={closeDialog}
title="Dialog Title"
subtitle="Dialog Subtitle"
variant="primary"
size="md"
>
<p>This is the content of the dialog.</p>
</Dialog>
</div>
);
};
export default App;
Prop | Type | Default | Description |
---|---|---|---|
isOpen | boolean | false | Whether the dialog is open or not. |
onClose | function | null | Callback function to handle closing the dialog. |
title | string | '' | The title of the dialog. |
subtitle | string | '' | The subtitle of the dialog. |
children | node | null | The content to display inside the dialog. |
variant | string | primary | The dialog variant. Can be primary , secondary , tertiary , success , or error . |
size | string | md | The size of the dialog. Can be sm , md , or lg . |
className | string | '' | Additional class names to apply to the dialog. |
...props | object | {} | Additional props to pass to the dialog element. |
import * as React from 'react';
import Dialog from 'abaabil.dialog';
import Button from 'abaabil.button';
const Example = () => {
const [isOpen, setIsOpen] = React.useState(false);
const openDialog = () => setIsOpen(true);
const closeDialog = () => setIsOpen(false);
return (
<div>
<Button onClick={openDialog}>Open Dialog</Button>
<Dialog
isOpen={isOpen}
onClose={closeDialog}
title="Dialog Title"
subtitle="Dialog Subtitle"
variant="primary"
size="md"
>
<p>This is the content of the dialog.</p>
</Dialog>
</div>
);
};
export default Example;
This example demonstrates various ways to use the Dialog
component, showcasing different variants, sizes, and states.
FAQs
Unknown package
The npm package abaabil.dialog receives a total of 2 weekly downloads. As such, abaabil.dialog popularity was classified as not popular.
We found that abaabil.dialog demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.