Skip to content

Commit 0967d5a

Browse files
committed
Refactor ComponentsPage to use the new CollapsibleNav
1 parent 333c663 commit 0967d5a

File tree

7 files changed

+14
-12
lines changed

7 files changed

+14
-12
lines changed

docs/examples/.eslintrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"Button",
1414
"ButtonGroup",
1515
"ButtonToolbar",
16-
"CollapsableNav",
16+
"CollapsibleNav",
1717
"CollapsibleMixin",
1818
"Carousel",
1919
"CarouselItem",

docs/examples/CollapsableNav.js renamed to docs/examples/CollapsibleNav.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
const navbarInstance = (
22
<Navbar brand='React-Bootstrap' toggleNavKey={0}>
3-
<CollapsableNav eventKey={0}> {/* This is the eventKey referenced */}
3+
<CollapsibleNav eventKey={0}> {/* This is the eventKey referenced */}
44
<Nav navbar>
55
<NavItem eventKey={1} href='#'>Link</NavItem>
66
<NavItem eventKey={2} href='#'>Link</NavItem>
@@ -16,7 +16,7 @@ const navbarInstance = (
1616
<NavItem eventKey={1} href='#'>Link Right</NavItem>
1717
<NavItem eventKey={2} href='#'>Link Right</NavItem>
1818
</Nav>
19-
</CollapsableNav>
19+
</CollapsibleNav>
2020
</Navbar>
2121
);
2222

docs/src/ComponentsPage.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -351,7 +351,7 @@ const ComponentsPage = React.createClass({
351351
<p>By setting the property {React.DOM.code(null, 'defaultNavExpanded={true}')} the Navbar will start expanded by default.</p>
352352
<div className='bs-callout bs-callout-info'>
353353
<h4>Scrollbar overflow</h4>
354-
<p>The height of the collapsable is slightly smaller than the real height. To hide the scroll bar, add the following css to your style files.</p>
354+
<p>The height of the collapsible is slightly smaller than the real height. To hide the scroll bar, add the following css to your style files.</p>
355355
<pre>
356356
{React.DOM.code(null,
357357
'.navbar-collapse {\n' +
@@ -360,17 +360,17 @@ const ComponentsPage = React.createClass({
360360
)}
361361
</pre>
362362
</div>
363-
<ReactPlayground codeText={Samples.NavbarCollapsable} />
363+
<ReactPlayground codeText={Samples.NavbarCollapsible} />
364364

365365
<h3>Mobile Friendly (Multiple Nav Components)</h3>
366-
<p>To have a mobile friendly Navbar that handles multiple <code>Nav</code> components use <code>CollapsableNav</code>. The <code>toggleNavKey</code> must still be set, however, the corresponding <code>eventKey</code> must now be on the <code>CollapsableNav</code> component.</p>
366+
<p>To have a mobile friendly Navbar that handles multiple <code>Nav</code> components use <code>CollapsibleNav</code>. The <code>toggleNavKey</code> must still be set, however, the corresponding <code>eventKey</code> must now be on the <code>CollapsibleNav</code> component.</p>
367367
<div className="bs-callout bs-callout-info">
368368
<h4>Div collapse</h4>
369-
<p>The <code>navbar-collapse</code> div gets created as the collapsable element which follows the <a href="http://getbootstrap.com/components/#navbar-default">bootstrap</a> collapsable navbar documentation.</p>
369+
<p>The <code>navbar-collapse</code> div gets created as the collapsible element which follows the <a href="http://getbootstrap.com/components/#navbar-default">bootstrap</a> collapsible navbar documentation.</p>
370370
<pre>&lt;div class="collapse navbar-collapse"&gt;&lt;/div&gt;</pre>
371371
</div>
372372

373-
<ReactPlayground codeText={Samples.CollapsableNav} />
373+
<ReactPlayground codeText={Samples.CollapsibleNav} />
374374
</div>
375375

376376
{/* Tabbed Areas */}

docs/src/ReactPlayground.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import * as modBadge from '../../src/Badge';
66
import * as modmodButton from '../../src/Button';
77
import * as modButtonGroup from '../../src/ButtonGroup';
88
import * as modmodButtonToolbar from '../../src/ButtonToolbar';
9-
import * as modCollapsableNav from '../../src/CollapsableNav';
9+
import * as modCollapsibleNav from '../../src/CollapsibleNav';
1010
import * as modCollapsibleMixin from '../../src/CollapsibleMixin';
1111
import * as modCarousel from '../../src/Carousel';
1212
import * as modCarouselItem from '../../src/CarouselItem';
@@ -53,7 +53,7 @@ const Badge = modBadge.default;
5353
const Button = modmodButton.default;
5454
const ButtonGroup = modButtonGroup.default;
5555
const ButtonToolbar = modmodButtonToolbar.default;
56-
const CollapsableNav = modCollapsableNav.default;
56+
const CollapsibleNav = modCollapsibleNav.default;
5757
const CollapsibleMixin = modCollapsibleMixin.default;
5858
const Carousel = modCarousel.default;
5959
const CarouselItem = modCarouselItem.default;

docs/src/Samples.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,8 @@ export default {
5252
NavJustified: require('fs').readFileSync(__dirname + '/../examples/NavJustified.js', 'utf8'),
5353
NavbarBasic: require('fs').readFileSync(__dirname + '/../examples/NavbarBasic.js', 'utf8'),
5454
NavbarBrand: require('fs').readFileSync(__dirname + '/../examples/NavbarBrand.js', 'utf8'),
55-
NavbarCollapsable: require('fs').readFileSync(__dirname + '/../examples/NavbarCollapsable.js', 'utf8'),
56-
CollapsableNav: require('fs').readFileSync(__dirname + '/../examples/CollapsableNav.js', 'utf8'),
55+
NavbarCollapsible: require('fs').readFileSync(__dirname + '/../examples/NavbarCollapsible.js', 'utf8'),
56+
CollapsibleNav: require('fs').readFileSync(__dirname + '/../examples/CollapsibleNav.js', 'utf8'),
5757
TabbedAreaUncontrolled: require('fs').readFileSync(__dirname + '/../examples/TabbedAreaUncontrolled.js', 'utf8'),
5858
TabbedAreaControlled: require('fs').readFileSync(__dirname + '/../examples/TabbedAreaControlled.js', 'utf8'),
5959
TabbedAreaNoAnimation: require('fs').readFileSync(__dirname + '/../examples/TabbedAreaNoAnimation.js', 'utf8'),

src/index.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import Button from './Button';
88
import ButtonGroup from './ButtonGroup';
99
import ButtonToolbar from './ButtonToolbar';
1010
import CollapsableNav from './CollapsableNav';
11+
import CollapsibleNav from './CollapsibleNav';
1112
import Carousel from './Carousel';
1213
import CarouselItem from './CarouselItem';
1314
import Col from './Col';
@@ -60,6 +61,7 @@ export default {
6061
ButtonGroup,
6162
ButtonToolbar,
6263
CollapsableNav,
64+
CollapsibleNav,
6365
Carousel,
6466
CarouselItem,
6567
Col,

0 commit comments

Comments
 (0)