Skip to content

Commit 602b775

Browse files
committed
New Docs - cleanup sidebar
1 parent 5feef63 commit 602b775

File tree

11 files changed

+45
-33
lines changed

11 files changed

+45
-33
lines changed

docs/foundation/assets.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
---
2-
index: 6
3-
path: "/foundation/assets"
2+
sidebar_position: 3
3+
sidebar_label: Assets
44
title: "Assets"
55
---
6+
67
Assets are a big part of the whole UI system, whether it's an icon, placeholder or an illustration, we use them everywhere.
78
Load groups of assets and easily render them with the _Image_ component.
89

docs/foundation/colors.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
---
2-
sidebar_position: 7
3-
path: "/foundation/colors"
2+
sidebar_position: 2
3+
sidebar_label: Colors
44
title: "Colors"
55
---
66

7-
#### loadColors
7+
### loadColors
88
Load a set of colors to be used in the app.
99
These colors will be accessible through the Colors class and as modifiers.
1010
usage:
@@ -27,7 +27,7 @@ import {View, Text, Colors} from 'react-native-ui-lib';
2727
<View>
2828
```
2929

30-
#### loadSchemes
30+
### loadSchemes
3131
Load a set of scheme colors to support dark/light mode.
3232
This feature works hand in hand with our modifiers
3333

@@ -58,7 +58,7 @@ Colors.loadSchemes({
5858
</View>
5959
```
6060

61-
#### rgba
61+
### rgba
6262
usage:
6363
```js
6464
import {Colors} from 'react-native-ui-lib';
@@ -67,7 +67,7 @@ Colors.rgba('#ff2442', 0.05); // 'rgb(255, 36, 66, 0.05)'
6767
Colors.rgba(44, 224, 112, 0.2); // 'rgb(44, 224, 112, 0.2)'
6868
```
6969

70-
#### getColorTint
70+
### getColorTint
7171
usage:
7272
```js
7373
import {Colors} from 'react-native-ui-lib';
@@ -76,7 +76,7 @@ Colors.getColorTint(Colors.green30, 70); // will return the value of Colors.gree
7676
Colors.getColorTint('#ff2442', 50); // will return the 5th tint in an autogenerate 8-tints palette based on '#ff2442'
7777
```
7878

79-
#### isDark
79+
### isDark
8080
returns `true` if a color is considered dark (bright colors will return `false`)
8181
```js
8282
import {Colors} from 'react-native-ui-lib';

docs/foundation/modifiers.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
---
2-
index: 5
3-
path: "/foundation/modifiers"
2+
sidebar_position: 4
3+
sidebar_label: Modifiers
44
title: "Modifiers"
55
---
6+
67
As you have probably noticed already, we translate our style presets into modifiers.
78
**Modifiers** help you create a stunning UI easily and quickly.
89

docs/foundation/style.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
---
2-
sidebar_position: 4
3-
path: "/foundation/style"
2+
sidebar_position: 1
3+
sidebar_label: Style
44
title: "Style"
55
---
6+
67
The base foundation of each UI component is its style.
78
We use basic style presets to define the rules and the style guide we follow.
89

docs/foundation/theme-manager.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
---
2-
index: 7
3-
path: "/foundation/theme-manager"
4-
title: "Theme Manager"
2+
sidebar_position: 5
3+
sidebar_label: ThemeManager
4+
title: "ThemeManager"
55
---
6+
67
Use `ThemeManager` to set default global behavior for your app.
78

89
#### setComponentTheme

docs/getting-started/setup.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
---
2-
index: 1
32
sidebar_position: 1
4-
path: "/getting-started/setup"
3+
sidebar_label: Setup
54
title: "Setup"
5+
# path: "/getting-started/setup"
66
---
77

88
## Before You Start: UILib Packages

docs/getting-started/usage.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
---
2-
index: 2
32
sidebar_position: 2
4-
path: "/getting-started/usage"
3+
sidebar_label: Usage
54
title: "Usage"
5+
# path: "/getting-started/usage"
66
---
77
This is a quick example of how to use our basic components, modifiers and presets to generate a good looking screen.
88
For detailed information please go over the other sections: [Style](../foundation/style.md), [Modifiers](../foundation/modifiers.md), Components...

docs/getting-started/v5.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
---
2-
index: 3
32
sidebar_position: 3
4-
path: "/getting-started/v5"
5-
title: "v4 -> v5"
3+
sidebar_label: Migrating v4 -> v5
4+
title: "Migrating v4 -> v5"
5+
# path: "/getting-started/v5"
66
---
77
88

docs/getting-started/v6.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
---
2-
index: 3.5
3-
path: "/getting-started/v6"
4-
title: "v5 -> v6"
2+
sidebar_position: 4
3+
sidebar_label: Migrating v5 -> v6
4+
title: "Migrating v5 -> v6"
5+
# path: "/getting-started/v6"
56
---
67
78

docuilib/docusaurus.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ const darkCodeTheme = require('prism-react-renderer/themes/dracula');
1616
projectName: 'react-native-ui-lib', // Usually your repo name.
1717
customFields: {
1818
expoSnackLink: 'https://snack.expo.io/@ethanshar/rnuilib_snack?platform=ios&supportedPlatforms=ios,android',
19-
stars: '3.8',
19+
stars: '3.8'
2020
},
2121
plugins: ['docusaurus-plugin-sass'],
2222
presets: [

docuilib/sidebars.js

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,22 +27,29 @@ module.exports = {
2727
{
2828
type: 'category',
2929
label: 'Getting Started',
30-
items: ['getting-started/setup', 'getting-started/usage', 'getting-started/v5', 'getting-started/v6']
30+
collapsed: false,
31+
items: [
32+
{
33+
type: 'autogenerated',
34+
dirName: `getting-started`
35+
}
36+
]
3137
},
3238
{
3339
type: 'category',
3440
label: 'Foundation',
41+
collapsed: false,
3542
items: [
36-
'foundation/style',
37-
'foundation/modifiers',
38-
'foundation/assets',
39-
'foundation/theme-manager',
40-
'foundation/colors'
43+
{
44+
type: 'autogenerated',
45+
dirName: `foundation`
46+
}
4147
]
4248
},
4349
{
4450
type: 'category',
4551
label: 'Components',
52+
collapsible: false,
4653
items: ['Basic', 'Form', 'Overlays', 'Layout', 'Lists', 'Native', 'Incubator'].map(category => {
4754
return {
4855
type: 'category',

0 commit comments

Comments
 (0)