-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Co-authored-by: “BogdanDanilescu” <bogdan.danilescu@nearform.com>
- Loading branch information
1 parent
0ad4219
commit 0afc349
Showing
24 changed files
with
672 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,7 @@ draft: false | |
status: stable | ||
--- | ||
|
||
# Actions | ||
# Alert | ||
|
||
<ComponentStatusBlock componentId="alert" /> | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,172 @@ | ||
--- | ||
title: Toast | ||
description: Toast HTML Component | ||
draft: false | ||
status: stable | ||
--- | ||
|
||
# Toast | ||
|
||
<ComponentStatusBlock componentId="toast" /> | ||
|
||
## Toast without trigger | ||
|
||
This toast will automatically appear when the page loads. \ | ||
*Refresh the current to see the toast being rendered* | ||
|
||
<Toast title="Toast" description="This toast has rendered on page load" /> | ||
|
||
<Tabs id="tab1"> | ||
<TabList> | ||
<TabItem value="tab11" checked>Macro</TabItem> | ||
<TabItem value="tab12">React</TabItem> | ||
</TabList> | ||
<TabPanel value="tab11"> | ||
```html | ||
{{ govieToast({ | ||
"title": "Toast", | ||
"description": "This toast has rendered on page load", | ||
}) }} | ||
``` | ||
</TabPanel> | ||
<TabPanel value="tab12"> | ||
```react | ||
import { Toast } from '@govie-ds/react'; | ||
|
||
<Toast | ||
title="Toast" | ||
description="This toast has rendered on page load" | ||
/> | ||
``` | ||
</TabPanel> | ||
</Tabs> | ||
## Info Toast with trigger | ||
<Toast title="Toast Triggered" description="This is an info toast" trigger={<Button>Trigger Toast</Button>}/> | ||
|
||
<Tabs id="tab2"> | ||
<TabList> | ||
<TabItem value="tab21" checked>Macro</TabItem> | ||
<TabItem value="tab22">React</TabItem> | ||
</TabList> | ||
<TabPanel value="tab21"> | ||
```html | ||
{{ govieToast({ | ||
"title": "Toast Triggered", | ||
"description": "This is an info toast", | ||
"trigger": { | ||
"content": "Trigger Toast" | ||
} | ||
}) }} | ||
``` | ||
</TabPanel> | ||
<TabPanel value="tab22"> | ||
```react | ||
import { Toast } from '@govie-ds/react'; | ||
|
||
<Toast | ||
title="Toast Triggered" | ||
description="This is an info toast" | ||
trigger={<Button>Trigger Toast</Button>} | ||
/> | ||
``` | ||
</TabPanel> | ||
</Tabs> | ||
## Success Toast with trigger | ||
<Toast title="Toast Triggered" variant="success" description="This is a success toast" trigger={<Button>Trigger Toast</Button>}/> | ||
|
||
<Tabs id="tab3"> | ||
<TabList> | ||
<TabItem value="tab31" checked>Macro</TabItem> | ||
<TabItem value="tab32">React</TabItem> | ||
</TabList> | ||
<TabPanel value="tab31"> | ||
```html | ||
{{ govieToast({ | ||
"title": "Toast Triggered", | ||
"description": "This is a success toast", | ||
"variant": "success", | ||
"trigger": { | ||
"content": "Trigger Toast" | ||
} | ||
}) }} | ||
``` | ||
</TabPanel> | ||
<TabPanel value="tab32"> | ||
```react | ||
import { Toast } from '@govie-ds/react'; | ||
|
||
<Toast | ||
title="Toast Triggered" | ||
variant="success" | ||
description="This is a success toast" | ||
trigger={<Button>Trigger Toast</Button>} | ||
/> | ||
``` | ||
</TabPanel> | ||
</Tabs> | ||
## Error Toast with trigger | ||
<Toast title="Toast Triggered" variant="danger" description="This is an error toast" trigger={<Button>Trigger Toast</Button>}/> | ||
|
||
<Tabs id="tab4"> | ||
<TabList> | ||
<TabItem value="tab41" checked>Macro</TabItem> | ||
<TabItem value="tab42">React</TabItem> | ||
</TabList> | ||
<TabPanel value="tab41"> | ||
```html | ||
{{ govieToast({ | ||
"title": "Toast Triggered", | ||
"description": "This is an error toast", | ||
"variant": "danger", | ||
"trigger": { | ||
"content": "Trigger Toast" | ||
} | ||
}) }} | ||
``` | ||
</TabPanel> | ||
<TabPanel value="tab42"> | ||
```react | ||
import { Toast } from '@govie-ds/react'; | ||
|
||
<Toast | ||
title="Toast Triggered" | ||
variant="danger" | ||
description="This is an error toast" | ||
trigger={<Button>Trigger Toast</Button>} | ||
/> | ||
``` | ||
</TabPanel> | ||
</Tabs> | ||
## Warning Toast with trigger | ||
<Toast title="Toast Triggered" variant="warning" description="This is a warning toast" trigger={<Button>Trigger Toast</Button>}/> | ||
|
||
<Tabs id="tab5"> | ||
<TabList> | ||
<TabItem value="tab51" checked>Macro</TabItem> | ||
<TabItem value="tab52">React</TabItem> | ||
</TabList> | ||
<TabPanel value="tab51"> | ||
```html | ||
{{ govieToast({ | ||
"title": "Toast Triggered", | ||
"description": "This is a warning toast", | ||
"variant": "warning", | ||
"trigger": { | ||
"content": "Trigger Toast" | ||
} | ||
}) }} | ||
``` | ||
</TabPanel> | ||
<TabPanel value="tab52"> | ||
```react | ||
import { Toast } from '@govie-ds/react'; | ||
|
||
<Toast | ||
title="Toast Triggered" | ||
variant="warning" | ||
description="This is a warning toast" | ||
trigger={<Button>Trigger Toast</Button>} | ||
/> | ||
``` | ||
</TabPanel> | ||
</Tabs> |
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.