1.0.21 • Published 11 months ago
@hudoro/dialog v1.0.21
Hudoro Dialog
Hudoro Dialog is a strict and customizable dialog component for web development projects, designed for simplicity and adherence to strict design guidelines.
Screenshots

Package instalation
Instal package using pnpm
pnpm add @hudoro/dialogInstal package using yarn
yarn add @hudoro/dialogInstal package using npm
npm i @hudoro/dialogimport package to your project
import {Dialog, DialogBody, DialogFooter, DialogTitle} from '@hudoro/dialog'Usage/Examples (you can combine using any package hudoro)
import {Dialog, DialogBody, DialogFooter, DialogTitle} from "@hudoro/dialog";
import {Button} from "@hudoro/button";
import {Box} from "@hudoro/box";
import {Text} from "@hudoro/text";
const App = () => {
const [show, setShow] = useState(false);
const toggleShow = () => {
setShow((prev) => !prev);
};
return (
<div>
<Button warning onClick={toggleShow}>
show
</Button>
<Dialog isShow={show} onHide={toggleShow}>
<DialogTitle danger>Are you sure dani sooo tamvan?</DialogTitle>
<DialogBody>
<Text
//any text props goes here
>
dani is so so so tamvan
</Text>
</DialogBody>
<DialogFooter>
<Box
//any box props goes here
>
<Button link onClick={toggleShow}>
no no
</Button>
<Button danger>Yes Delete this</Button>
</Box>
</DialogFooter>
</Dialog>
</div>
);
};Props @hudoro/dialog
Props that you can pass to <Dialog {...props}>
| Prop Name | Type | Value | Default | required |
|---|---|---|---|---|
| children | ReactNode | ReactNode | ReactNode | true |
| isShow | boolean | false / true | false | true |
| onHide | () => void | () => {your logic} | () => {} | true |
Props that you can pass to <DialogTitle {...props}>
| Prop Name | Type | Value | Default | required | description |
|---|---|---|---|---|---|
| children | ReactNode | ReactNode | ReactNode | true | "" |
| info | boolean | false/true | false | false | svg with type info will appear next to the left title |
| success | boolean | false/true | false | false | svg with type success will appear next to the left title |
| danger | boolean | false/true | false | false | svg with type danger will appear next to the left title |
Props that you can pass to <DialogBody {...props}>
| Prop Name | Type | Value | Default | required | description |
|---|---|---|---|---|---|
| children | ReactNode | ReactNode | ReactNode | true | "" |
Props that you can pass to <DialogFooter {...props}>
| Prop Name | Type | Value | Default | required | description |
|---|---|---|---|---|---|
| children | ReactNode | ReactNode | ReactNode | true | "" |
1.0.19
1 year ago
1.0.18
1 year ago
1.0.17
1 year ago
1.0.21
11 months ago
1.0.20
1 year ago
1.0.15
1 year ago
1.0.14
1 year ago
1.0.13
1 year ago
1.0.12
1 year ago
1.0.11
1 year ago
1.0.9
2 years ago
1.0.8
2 years ago
1.0.7
2 years ago
1.0.6
2 years ago
1.0.10
2 years ago
1.0.5
2 years ago
1.0.2
2 years ago
1.0.4
2 years ago
1.0.3
2 years ago
1.0.1
2 years ago
0.0.1-beta.3
2 years ago