Update README.md
Removed extra space and updated readme to have heading and sub heading
This commit is contained in:
parent
f35b9003fe
commit
ed18749fda
19
README.md
19
README.md
|
@ -1,11 +1,12 @@
|
|||
# Y—Catalog-Viewer
|
||||
A standalone catalog viewer package that intelligently displays design components.
|
||||
|
||||
|
||||
### Sample code to display built-in components
|
||||
|
||||
Usage
|
||||
----------
|
||||
A user can use built-in components like Icon Category, Font Category, and Color Category to display icons, fonts, and colors respectively.
|
||||
|
||||
|
||||
### Icon Category
|
||||
For example, a user can create an icon category as follows:
|
||||
|
||||
```
|
||||
|
@ -35,6 +36,7 @@ where the user needs to provide the following parameters:
|
|||

|
||||
|
||||
|
||||
### Font Category
|
||||
a user can create a font category as follows:
|
||||
```
|
||||
enum FontSample {
|
||||
|
@ -54,7 +56,6 @@ enum FontSample {
|
|||
}
|
||||
|
||||
```
|
||||
|
||||
where the user needs to provide the following parameters:
|
||||
* The name of the category.
|
||||
* Model for the font to be displayed, which again includes:
|
||||
|
@ -66,6 +67,7 @@ where the user needs to provide the following parameters:
|
|||

|
||||
|
||||
|
||||
### Color category
|
||||
a user can create a color category as follows:
|
||||
```
|
||||
enum ColorSample {
|
||||
|
@ -95,6 +97,7 @@ where the user needs to provide the following parameters:
|
|||

|
||||
|
||||
|
||||
### Catalog Category
|
||||
We can create a category which contains other categories.
|
||||
```
|
||||
let foundationalCategory = CatalogCategory(
|
||||
|
@ -113,10 +116,7 @@ We can create a category which contains other categories.
|
|||

|
||||
|
||||
|
||||
### Sample code to display Custom Components
|
||||
|
||||
We can use Custom Category to display components like buttons, views within design system
|
||||
|
||||
### Custom Component Category
|
||||
Suppose a user wants to display a button named DemoButton from their project.
|
||||
```
|
||||
enum DemoButtonSample {
|
||||
|
@ -144,6 +144,7 @@ enum DemoButtonSample {
|
|||

|
||||
|
||||
|
||||
### Custom View Category
|
||||
We can display a custom view within the catalog.
|
||||
Suppose a user wants to display a custom view named DemoView from their project.
|
||||
```
|
||||
|
@ -161,7 +162,6 @@ enum DemoButtonSample {
|
|||
)
|
||||
}
|
||||
}
|
||||
|
||||
```
|
||||
where the user needs to provide the following parameters:
|
||||
* name for the category.
|
||||
|
@ -170,6 +170,7 @@ enum DemoButtonSample {
|
|||

|
||||
|
||||
|
||||
### Custom View Controller category
|
||||
We can display view controllers in the catalog
|
||||
1. First create a custom destination that returns the view controller
|
||||
```
|
||||
|
|
Loading…
Reference in New Issue