-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
change the way we display the button in the portal. This is still WIP…
…, and will be changes overtime to all components.
- Loading branch information
1 parent
9e86370
commit 1df2ef6
Showing
18 changed files
with
173 additions
and
109 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 |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
title: 'Accordion' | ||
draft: false | ||
status: 'wip' | ||
# order: 1 | ||
order: 1 | ||
--- | ||
|
||
import Tabs from 'Tags/Tabs' | ||
|
33 changes: 9 additions & 24 deletions
33
packages/dnb-design-system-portal/src/pages/uilib/components/button.md
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 |
---|---|---|
@@ -1,40 +1,25 @@ | ||
--- | ||
title: 'Button' | ||
draft: false | ||
status: null | ||
order: 1 | ||
order: 2 | ||
--- | ||
|
||
import Tabs from 'Tags/Tabs' | ||
import ComponentBox from 'Tags/ComponentBox' | ||
import Description from 'Pages/uilib/components/button/description' | ||
import Details from 'Pages/uilib/components/button/details' | ||
import Demos from 'Pages/uilib/components/button/Examples' | ||
|
||
import FirstTabContent from 'Pages/uilib/components/button/first-tab-content' | ||
import SecondTabContent from 'Pages/uilib/components/button/second-tab-content' | ||
import ThirdTabContent from 'Pages/uilib/components/button/third-tab-content' | ||
|
||
# Button | ||
|
||
<Tabs> | ||
<Tabs.Content> | ||
<Description /> | ||
<h2>Demos</h2> | ||
<Demos /> | ||
<FirstTabContent /> | ||
</Tabs.Content> | ||
<Tabs.Content> | ||
<Details /> | ||
<ComponentBox caption="Test"> | ||
{` | ||
<Button | ||
text="Secondary button with text only 2" | ||
variant="secondary" | ||
title="This is a button title" | ||
/> | ||
`} | ||
</ComponentBox> | ||
<SecondTabContent /> | ||
</Tabs.Content> | ||
<Tabs.Content title="Markup"> | ||
<h2>H2</h2> | ||
<Tabs.Content> | ||
<ThirdTabContent /> | ||
</Tabs.Content> | ||
</Tabs> | ||
|
||
<!-- import ButtonPage from 'Src/uilib/components/demos/Button' --> | ||
<!-- <ButtonPage /> --> |
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
9 changes: 0 additions & 9 deletions
9
packages/dnb-design-system-portal/src/pages/uilib/components/button/demos.md
This file was deleted.
Oops, something went wrong.
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
Empty file.
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
9 changes: 9 additions & 0 deletions
9
...dnb-design-system-portal/src/pages/uilib/components/button/third-tab-content.md
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,9 @@ | ||
--- | ||
draft: true | ||
--- | ||
|
||
## Events | ||
|
||
| Events | Description | | ||
| ---------- | --------------------------------------------- | | ||
| `on_click` | _(optional)_ will be called on a click event. | |
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
21 changes: 21 additions & 0 deletions
21
packages/dnb-design-system-portal/src/shared/inlineTags/Markup.js
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,21 @@ | ||
/** | ||
* Inline Tag | ||
* | ||
*/ | ||
|
||
import React, { PureComponent } from 'react' | ||
import PropTypes from 'prop-types' | ||
import Code from '../parts/uilib/Code' | ||
|
||
export default class Markup extends PureComponent { | ||
static propTypes = { | ||
children: PropTypes.oneOfType([PropTypes.func, PropTypes.node]) | ||
} | ||
static defaultProps = { | ||
children: null | ||
} | ||
render() { | ||
const { children } = this.props | ||
return <Code source={children} /> | ||
} | ||
} |
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
Oops, something went wrong.