Skip to content

Commit 4218a9c

Browse files
committed
docs: update documentation
1 parent 9e3df6b commit 4218a9c

File tree

5 files changed

+59
-24
lines changed

5 files changed

+59
-24
lines changed

docs/4.0/components/CBreadcrumb.mdx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
---
22
title: React Breadcrumb Component
33
name: Breadcrumb
4+
description: React breadcrumb navigation component which indicates the current ___location within a navigational hierarchy that automatically adds separators.
5+
46
menu: Components
57
route: /components/breadcrumb
68
---

docs/4.0/components/CButton.mdx

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ route: /components/buttons
77
---
88

99
import { Playground, Props } from 'docz'
10-
import { CButton } from '../../../src/index.ts'
10+
import { CButton, CCallout } from '../../../src/index.ts'
1111

1212
## Examples
1313

@@ -25,12 +25,12 @@ CoreUI includes a bunch of predefined buttons components, each serving its own s
2525
<CButton color="link">Link</CButton>
2626
</Playground>
2727

28-
<div className="callout callout-info">
28+
<CCallout color="info">
2929
<h5>Conveying meaning to assistive technologies</h5>
3030
<p>
3131
Using color to add meaning only provides a visual indication, which will not be conveyed to users of assistive technologies – such as screen readers. Ensure that information denoted by the color is either obvious from the content itself (e.g. the visible text), or is included through alternative means, such as additional text hidden with the `.visually-hidden` class.
3232
</p>
33-
</div>
33+
</CCallout>
3434

3535
## Disable text wrapping
3636

@@ -80,7 +80,9 @@ If you need a ghost variant of button, set `variant="ghost"` prop to remove all
8080
<CButton color="dark" variant="ghost">Dark</CButton>
8181
</Playground>
8282

83-
CALLOUT: Some of the button styles use a relatively light foreground color, and should only be used on a dark background in order to have sufficient contrast.
83+
<CCallout color="info">
84+
Some of the button styles use a relatively light foreground color, and should only be used on a dark background in order to have sufficient contrast.
85+
</CCallout>
8486

8587
## Sizes
8688

docs/4.0/components/CHeader.mdx

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import { Playground, Props } from 'docz'
1111
import { useState } from 'react'
1212

1313
import {
14+
CButton,
1415
CContainer,
1516
CCollapse,
1617
CDropdown,
@@ -20,6 +21,8 @@ import {
2021
CDropdownItemPlain,
2122
CDropdownMenu,
2223
CDropdownToggle,
24+
CForm,
25+
CFormInput,
2326
CNav,
2427
CNavItem,
2528
CNavLink,
@@ -46,12 +49,12 @@ Here's what you need to know before getting started with the header:
4649

4750
Headers come with built-in support for a handful of sub-components. Choose from the following as needed:
4851

49-
- `.header-brand` for your company, product, or project name.
50-
- `.header-nav` for a full-height and lightweight navigation (including support for dropdowns).
51-
- `.header-toggler` for use with our collapse plugin and other [navigation toggling](#responsive-behaviors) behaviors.
52+
- `<CHeaderBrand>` for your company, product, or project name.
53+
- `<CHeaderNav>` for a full-height and lightweight navigation (including support for dropdowns).
54+
- `<CHeaderToggler>` for use with our collapse plugin and other [navigation toggling](#responsive-behaviors) behaviors.
5255
- Flex and spacing utilities for any form controls and actions.
53-
- `.header-text` for adding vertically centered strings of text.
54-
- `.collapse.header-collapse` for grouping and hiding header contents by a parent breakpoint.
56+
- `<CHeaderText>` for adding vertically centered strings of text.
57+
- `<CCollapse className="header-collapse">` for grouping and hiding header contents by a parent breakpoint.
5558

5659
Here's an example of all the sub-components included in a responsive light-themed header that automatically collapses at the `lg` (large) breakpoint.
5760

@@ -91,10 +94,10 @@ Here's an example of all the sub-components included in a responsive light-theme
9194
</CNavLink>
9295
</CNavItem>
9396
</CHeaderNav>
94-
{/* <form className="d-flex">
95-
<input className="form-control me-2" type="search" placeholder="Search">
96-
<button className="btn btn-outline-success" type="submit">Search</button>
97-
</form> */}
97+
<CForm className="d-flex">
98+
<CFormInput className="me-2" type="search" placeholder="Search"/>
99+
<CButton type="submit" color="success" variant="outline">Search</CButton>
100+
</CForm>
98101
</CCollapse>
99102
</CContainer>
100103
</CHeader>

docs/4.0/components/COffcanvas.mdx

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ import {
2323

2424
### Offcanvas components
2525

26-
Below is an offcanvas example that is shown by default (via `.show` on `.offcanvas`). Offcanvas includes support for a header with a close button and an optional body class for some initial `padding`. We suggest that you include offcanvas headers with dismiss actions whenever possible, or provide an explicit dismiss action.
26+
Below is an offcanvas example that is shown by default (via `visible={true}`). Offcanvas includes support for a header with a close button and an optional body class for some initial `padding`. We suggest that you include offcanvas headers with dismiss actions whenever possible, or provide an explicit dismiss action.
2727

2828
<Playground>
2929
<div className="docs-example-offcanvas bg-light">
@@ -42,12 +42,10 @@ Below is an offcanvas example that is shown by default (via `.show` on `.offcanv
4242

4343
### Live demo
4444

45-
Use the buttons below to show and hide an offcanvas element via JavaScript that toggles the `.show` class on an element with the `.offcanvas` class.
45+
Use the buttons below to show and hide an offcanvas component.
4646

47-
- `.offcanvas` hides content (default)
48-
- `.offcanvas.show` shows content
49-
50-
You can use a link with the `href` attribute, or a button with the `data-coreui-target` attribute. In both cases, the `data-coreui-toggle="offcanvas"` is required.
47+
- `visible={false}` hides content (default)
48+
- `visible` or `visible={true}` shows content
5149

5250
<Playground>
5351
{() => {
@@ -74,10 +72,10 @@ You can use a link with the `href` attribute, or a button with the `data-coreui-
7472

7573
There's no default placement for offcanvas components, so you must add one of the modifier classes below;
7674

77-
- `.offcanvas-start` places offcanvas on the left of the viewport (shown above)
78-
- `.offcanvas-end` places offcanvas on the right of the viewport
79-
- `.offcanvas-top` places offcanvas on the top of the viewport
80-
- `.offcanvas-bottom` places offcanvas on the bottom of the viewport
75+
- `placement="start"` places offcanvas on the left of the viewport (shown above)
76+
- `placement="end"` places offcanvas on the right of the viewport
77+
- `placement="top"` places offcanvas on the top of the viewport
78+
- `placement="bottom"` places offcanvas on the bottom of the viewport
8179

8280
Try the top, right, and bottom examples out below.
8381

docs/4.0/components/CTable.mdx

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1173,4 +1173,34 @@ Responsive tables allow tables to be scrolled horizontally with ease. Make any t
11731173
</CTableRow>
11741174
</CTableBody>
11751175
</CTable>
1176-
</Playground>
1176+
</Playground>
1177+
1178+
## API
1179+
1180+
### CTable
1181+
1182+
<Props of={CTable} />
1183+
1184+
### CTableBody
1185+
1186+
<Props of={CTableBody} />
1187+
1188+
### CTableDataCell
1189+
1190+
<Props of={CTableDataCell} />
1191+
1192+
### CTableFoot
1193+
1194+
<Props of={CTableFoot} />
1195+
1196+
### CTableHead
1197+
1198+
<Props of={CTableHead} />
1199+
1200+
### CTableHeaderCell
1201+
1202+
<Props of={CTableHeaderCell} />
1203+
1204+
### CTableRow
1205+
1206+
<Props of={CTableRow} />

0 commit comments

Comments
 (0)