From 7ef03ec35e10ce2195128e5584410157fec0e23b Mon Sep 17 00:00:00 2001 From: Johannes Lumpe Date: Wed, 14 Nov 2018 09:52:37 -0500 Subject: [PATCH] feat: update docs (#13) --- docs/README.md | 10 ++++- docs/interfaces/_display_.idisplayprops.md | 30 ++++++++++++++ docs/interfaces/_flex_.iflexprops.md | 30 ++++++++++++++ .../interfaces/_textcolor_.itextcolorprops.md | 30 ++++++++++++++ docs/interfaces/_types_.ibasecssvalue.md | 4 +- docs/interfaces/_types_.ibreakpointtheme.md | 4 +- docs/interfaces/_types_.idictionary.md | 2 +- docs/interfaces/_types_.istyleoptions.md | 24 ++++++++--- docs/interfaces/_types_.istyles.md | 2 +- docs/interfaces/_types_.itheme.md | 4 +- docs/modules/_display_.md | 36 ++++++++++++++++ docs/modules/_flex_.md | 36 ++++++++++++++++ docs/modules/_index_.md | 8 ++++ docs/modules/_style_.md | 28 ++++++++++--- docs/modules/_textcolor_.md | 41 +++++++++++++++++++ docs/modules/_types_.md | 14 +++---- 16 files changed, 276 insertions(+), 27 deletions(-) create mode 100644 docs/interfaces/_display_.idisplayprops.md create mode 100644 docs/interfaces/_flex_.iflexprops.md create mode 100644 docs/interfaces/_textcolor_.itextcolorprops.md create mode 100644 docs/modules/_display_.md create mode 100644 docs/modules/_flex_.md create mode 100644 docs/modules/_index_.md create mode 100644 docs/modules/_textcolor_.md diff --git a/docs/README.md b/docs/README.md index 533f4ef..0d574e1 100644 --- a/docs/README.md +++ b/docs/README.md @@ -1,9 +1,15 @@ -# styled-props +# @johanneslumpe/styled-props -## External modules +## Index +### External modules + +* ["display"](modules/_display_.md) +* ["flex"](modules/_flex_.md) +* ["index"](modules/_index_.md) * ["style"](modules/_style_.md) +* ["textColor"](modules/_textcolor_.md) * ["types"](modules/_types_.md) --- diff --git a/docs/interfaces/_display_.idisplayprops.md b/docs/interfaces/_display_.idisplayprops.md new file mode 100644 index 0000000..953540c --- /dev/null +++ b/docs/interfaces/_display_.idisplayprops.md @@ -0,0 +1,30 @@ +[@johanneslumpe/styled-props](../README.md) > ["display"](../modules/_display_.md) > [IDisplayProps](../interfaces/_display_.idisplayprops.md) + +# Interface: IDisplayProps + +## Type parameters +#### T +## Hierarchy + +**IDisplayProps** + +## Index + +### Properties + +* [display](_display_.idisplayprops.md#display) + +--- + +## Properties + + + +### display + +**● display**: *`T`* + +*Defined in [display.ts:6](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/display.ts#L6)* + +___ + diff --git a/docs/interfaces/_flex_.iflexprops.md b/docs/interfaces/_flex_.iflexprops.md new file mode 100644 index 0000000..0d2b32e --- /dev/null +++ b/docs/interfaces/_flex_.iflexprops.md @@ -0,0 +1,30 @@ +[@johanneslumpe/styled-props](../README.md) > ["flex"](../modules/_flex_.md) > [IFlexProps](../interfaces/_flex_.iflexprops.md) + +# Interface: IFlexProps + +## Type parameters +#### T +## Hierarchy + +**IFlexProps** + +## Index + +### Properties + +* [flex](_flex_.iflexprops.md#flex) + +--- + +## Properties + + + +### flex + +**● flex**: *`T`* + +*Defined in [flex.ts:6](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/flex.ts#L6)* + +___ + diff --git a/docs/interfaces/_textcolor_.itextcolorprops.md b/docs/interfaces/_textcolor_.itextcolorprops.md new file mode 100644 index 0000000..b33ac59 --- /dev/null +++ b/docs/interfaces/_textcolor_.itextcolorprops.md @@ -0,0 +1,30 @@ +[@johanneslumpe/styled-props](../README.md) > ["textColor"](../modules/_textcolor_.md) > [ITextColorProps](../interfaces/_textcolor_.itextcolorprops.md) + +# Interface: ITextColorProps + +## Type parameters +#### T +## Hierarchy + +**ITextColorProps** + +## Index + +### Properties + +* [textColor](_textcolor_.itextcolorprops.md#textcolor) + +--- + +## Properties + + + +### textColor + +**● textColor**: *`T`* + +*Defined in [textColor.ts:5](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/textColor.ts#L5)* + +___ + diff --git a/docs/interfaces/_types_.ibasecssvalue.md b/docs/interfaces/_types_.ibasecssvalue.md index 2eece9d..8478ad3 100644 --- a/docs/interfaces/_types_.ibasecssvalue.md +++ b/docs/interfaces/_types_.ibasecssvalue.md @@ -1,4 +1,4 @@ -[styled-props](../README.md) > ["types"](../modules/_types_.md) > [IBaseCssValue](../interfaces/_types_.ibasecssvalue.md) +[@johanneslumpe/styled-props](../README.md) > ["types"](../modules/_types_.md) > [IBaseCssValue](../interfaces/_types_.ibasecssvalue.md) # Interface: IBaseCssValue @@ -24,7 +24,7 @@ **● base**: *[T]()* -*Defined in [types.ts:5](https://github.com/johanneslumpe/styled-props/blob/892c9ca/src/types.ts#L5)* +*Defined in [types.ts:5](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/types.ts#L5)* The base css value, without any media queries applied diff --git a/docs/interfaces/_types_.ibreakpointtheme.md b/docs/interfaces/_types_.ibreakpointtheme.md index 7801d7f..1b5f0c8 100644 --- a/docs/interfaces/_types_.ibreakpointtheme.md +++ b/docs/interfaces/_types_.ibreakpointtheme.md @@ -1,4 +1,4 @@ -[styled-props](../README.md) > ["types"](../modules/_types_.md) > [IBreakpointTheme](../interfaces/_types_.ibreakpointtheme.md) +[@johanneslumpe/styled-props](../README.md) > ["types"](../modules/_types_.md) > [IBreakpointTheme](../interfaces/_types_.ibreakpointtheme.md) # Interface: IBreakpointTheme @@ -26,7 +26,7 @@ **● theme**: * `T` & `object` * -*Defined in [types.ts:36](https://github.com/johanneslumpe/styled-props/blob/892c9ca/src/types.ts#L36)* +*Defined in [types.ts:36](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/types.ts#L36)* ___ diff --git a/docs/interfaces/_types_.idictionary.md b/docs/interfaces/_types_.idictionary.md index 5d92439..d2b7067 100644 --- a/docs/interfaces/_types_.idictionary.md +++ b/docs/interfaces/_types_.idictionary.md @@ -1,4 +1,4 @@ -[styled-props](../README.md) > ["types"](../modules/_types_.md) > [IDictionary](../interfaces/_types_.idictionary.md) +[@johanneslumpe/styled-props](../README.md) > ["types"](../modules/_types_.md) > [IDictionary](../interfaces/_types_.idictionary.md) # Interface: IDictionary diff --git a/docs/interfaces/_types_.istyleoptions.md b/docs/interfaces/_types_.istyleoptions.md index e1fad1c..5b20c71 100644 --- a/docs/interfaces/_types_.istyleoptions.md +++ b/docs/interfaces/_types_.istyleoptions.md @@ -1,10 +1,11 @@ -[styled-props](../README.md) > ["types"](../modules/_types_.md) > [IStyleOptions](../interfaces/_types_.istyleoptions.md) +[@johanneslumpe/styled-props](../README.md) > ["types"](../modules/_types_.md) > [IStyleOptions](../interfaces/_types_.istyleoptions.md) # Interface: IStyleOptions ## Type parameters #### P #### T +#### K : `Extract`<`keyof T`, `string`> ## Hierarchy **IStyleOptions** @@ -13,6 +14,7 @@ ### Properties +* [arrayResolver](_types_.istyleoptions.md#arrayresolver) * [cssProp](_types_.istyleoptions.md#cssprop) * [prop](_types_.istyleoptions.md#prop) * [themeProp](_types_.istyleoptions.md#themeprop) @@ -21,13 +23,25 @@ ## Properties + + +### `` arrayResolver + +**● arrayResolver**: * `undefined` | `function` +* + +*Defined in [types.ts:69](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/types.ts#L69)* + +The resolver to be used for array values + +___ ### cssProp **● cssProp**: *`string`* -*Defined in [types.ts:50](https://github.com/johanneslumpe/styled-props/blob/892c9ca/src/types.ts#L50)* +*Defined in [types.ts:54](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/types.ts#L54)* The css property this function should map to @@ -38,7 +52,7 @@ ___ **● prop**: *`Extract`<`keyof P`, `string`>* -*Defined in [types.ts:54](https://github.com/johanneslumpe/styled-props/blob/892c9ca/src/types.ts#L54)* +*Defined in [types.ts:59](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/types.ts#L59)* The property of the component's props to read from @@ -47,9 +61,9 @@ ___ ### `` themeProp -**● themeProp**: *`Extract`<`keyof T`, `string`>* +**● themeProp**: *[K]()* -*Defined in [types.ts:58](https://github.com/johanneslumpe/styled-props/blob/892c9ca/src/types.ts#L58)* +*Defined in [types.ts:64](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/types.ts#L64)* The property within the theme to map the `prop` value to diff --git a/docs/interfaces/_types_.istyles.md b/docs/interfaces/_types_.istyles.md index 289792f..33809ea 100644 --- a/docs/interfaces/_types_.istyles.md +++ b/docs/interfaces/_types_.istyles.md @@ -1,4 +1,4 @@ -[styled-props](../README.md) > ["types"](../modules/_types_.md) > [IStyles](../interfaces/_types_.istyles.md) +[@johanneslumpe/styled-props](../README.md) > ["types"](../modules/_types_.md) > [IStyles](../interfaces/_types_.istyles.md) # Interface: IStyles diff --git a/docs/interfaces/_types_.itheme.md b/docs/interfaces/_types_.itheme.md index 7d530bc..cf7f28d 100644 --- a/docs/interfaces/_types_.itheme.md +++ b/docs/interfaces/_types_.itheme.md @@ -1,4 +1,4 @@ -[styled-props](../README.md) > ["types"](../modules/_types_.md) > [ITheme](../interfaces/_types_.itheme.md) +[@johanneslumpe/styled-props](../README.md) > ["types"](../modules/_types_.md) > [ITheme](../interfaces/_types_.itheme.md) # Interface: ITheme @@ -25,7 +25,7 @@ **● theme**: * `T` & `object` * -*Defined in [types.ts:32](https://github.com/johanneslumpe/styled-props/blob/892c9ca/src/types.ts#L32)* +*Defined in [types.ts:32](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/types.ts#L32)* ___ diff --git a/docs/modules/_display_.md b/docs/modules/_display_.md new file mode 100644 index 0000000..d3d83aa --- /dev/null +++ b/docs/modules/_display_.md @@ -0,0 +1,36 @@ +[@johanneslumpe/styled-props](../README.md) > ["display"](../modules/_display_.md) + +# External module: "display" + +## Index + +### Interfaces + +* [IDisplayProps](../interfaces/_display_.idisplayprops.md) + +### Functions + +* [display](_display_.md#display) + +--- + +## Functions + + + +### `` display + +▸ **display**T,Theme,Breakpoints(): `styleImplementation` + +*Defined in [display.ts:9](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/display.ts#L9)* + +**Type parameters:** + +#### T +#### Theme +#### Breakpoints + +**Returns:** `styleImplementation` + +___ + diff --git a/docs/modules/_flex_.md b/docs/modules/_flex_.md new file mode 100644 index 0000000..b44fa82 --- /dev/null +++ b/docs/modules/_flex_.md @@ -0,0 +1,36 @@ +[@johanneslumpe/styled-props](../README.md) > ["flex"](../modules/_flex_.md) + +# External module: "flex" + +## Index + +### Interfaces + +* [IFlexProps](../interfaces/_flex_.iflexprops.md) + +### Functions + +* [flex](_flex_.md#flex) + +--- + +## Functions + + + +### `` flex + +▸ **flex**T,Theme,Breakpoints(): `styleImplementation` + +*Defined in [flex.ts:9](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/flex.ts#L9)* + +**Type parameters:** + +#### T +#### Theme +#### Breakpoints + +**Returns:** `styleImplementation` + +___ + diff --git a/docs/modules/_index_.md b/docs/modules/_index_.md new file mode 100644 index 0000000..7ed1838 --- /dev/null +++ b/docs/modules/_index_.md @@ -0,0 +1,8 @@ +[@johanneslumpe/styled-props](../README.md) > ["index"](../modules/_index_.md) + +# External module: "index" + +## Index + +--- + diff --git a/docs/modules/_style_.md b/docs/modules/_style_.md index 838afb9..23b2b70 100644 --- a/docs/modules/_style_.md +++ b/docs/modules/_style_.md @@ -1,4 +1,4 @@ -[styled-props](../README.md) > ["style"](../modules/_style_.md) +[@johanneslumpe/styled-props](../README.md) > ["style"](../modules/_style_.md) # External module: "style" @@ -12,6 +12,7 @@ ### Functions +* [DEFAULT_ARRAY_RESOLVER](_style_.md#default_array_resolver) * [style](_style_.md#style) --- @@ -24,7 +25,7 @@ **● BASE_EMPTY_INDEXED_OBJECT**: *[IDictionary](../interfaces/_types_.idictionary.md)<`any`>* = BASE_EMPTY_OBJECT -*Defined in [style.ts:10](https://github.com/johanneslumpe/styled-props/blob/892c9ca/src/style.ts#L10)* +*Defined in [style.ts:4](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/style.ts#L4)* ___ @@ -33,7 +34,7 @@ ___ **● BASE_EMPTY_OBJECT**: *`object`* -*Defined in [style.ts:9](https://github.com/johanneslumpe/styled-props/blob/892c9ca/src/style.ts#L9)* +*Defined in [style.ts:3](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/style.ts#L3)* #### Type declaration @@ -44,19 +45,36 @@ ___ **● BREAKPOINTS_BASE_VALUE_KEY**: *"base"* = "base" -*Defined in [style.ts:11](https://github.com/johanneslumpe/styled-props/blob/892c9ca/src/style.ts#L11)* +*Defined in [style.ts:5](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/style.ts#L5)* ___ ## Functions + + +### `` DEFAULT_ARRAY_RESOLVER + +▸ **DEFAULT_ARRAY_RESOLVER**(value: *`Array`< `string` | `number`>*): `string` + +*Defined in [style.ts:7](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/style.ts#L7)* + +**Parameters:** + +| Param | Type | +| ------ | ------ | +| value | `Array`< `string` | `number`> | + +**Returns:** `string` + +___ ### style ▸ **style**P,T,B(__namedParameters: *`object`*): `styleImplementation` -*Defined in [style.ts:13](https://github.com/johanneslumpe/styled-props/blob/892c9ca/src/style.ts#L13)* +*Defined in [style.ts:10](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/style.ts#L10)* **Type parameters:** diff --git a/docs/modules/_textcolor_.md b/docs/modules/_textcolor_.md new file mode 100644 index 0000000..d104bdb --- /dev/null +++ b/docs/modules/_textcolor_.md @@ -0,0 +1,41 @@ +[@johanneslumpe/styled-props](../README.md) > ["textColor"](../modules/_textcolor_.md) + +# External module: "textColor" + +## Index + +### Interfaces + +* [ITextColorProps](../interfaces/_textcolor_.itextcolorprops.md) + +### Functions + +* [textColor](_textcolor_.md#textcolor) + +--- + +## Functions + + + +### `` textColor + +▸ **textColor**T,Theme,Breakpoints(__namedParameters?: *`object`*): `styleImplementation` + +*Defined in [textColor.ts:8](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/textColor.ts#L8)* + +**Type parameters:** + +#### T +#### Theme +#### Breakpoints +**Parameters:** + +| Param | Type | Default value | +| ------ | ------ | ------ | +| `Default value` __namedParameters | `object` | {} | + +**Returns:** `styleImplementation` + +___ + diff --git a/docs/modules/_types_.md b/docs/modules/_types_.md index 985a2ea..8ce1ed7 100644 --- a/docs/modules/_types_.md +++ b/docs/modules/_types_.md @@ -1,4 +1,4 @@ -[styled-props](../README.md) > ["types"](../modules/_types_.md) +[@johanneslumpe/styled-props](../README.md) > ["types"](../modules/_types_.md) # External module: "types" @@ -32,7 +32,7 @@ **ΤResponsiveObject**: *`object`* -*Defined in [types.ts:27](https://github.com/johanneslumpe/styled-props/blob/892c9ca/src/types.ts#L27)* +*Defined in [types.ts:27](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/types.ts#L27)* #### Type declaration @@ -43,7 +43,7 @@ ___ **ΤResponsiveProp**: *`ResponsiveProp<ValueType, BreakPoints>`* -*Defined in [types.ts:17](https://github.com/johanneslumpe/styled-props/blob/892c9ca/src/types.ts#L17)* +*Defined in [types.ts:17](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/types.ts#L17)* ___ @@ -53,7 +53,7 @@ ___ **ΤResponsivePropValue**: * `object` & [IBaseCssValue](../interfaces/_types_.ibasecssvalue.md)<`ValueType`> * -*Defined in [types.ts:12](https://github.com/johanneslumpe/styled-props/blob/892c9ca/src/types.ts#L12)* +*Defined in [types.ts:12](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/types.ts#L12)* ___ @@ -62,7 +62,7 @@ ___ **ΤStyleProps**: *`StyleProps<T>`* -*Defined in [types.ts:8](https://github.com/johanneslumpe/styled-props/blob/892c9ca/src/types.ts#L8)* +*Defined in [types.ts:8](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/types.ts#L8)* ___ @@ -71,7 +71,7 @@ ___ **ΤThemeWithBreakpoints**: *`ThemeWithBreakpoints<T, B>`* -*Defined in [types.ts:39](https://github.com/johanneslumpe/styled-props/blob/892c9ca/src/types.ts#L39)* +*Defined in [types.ts:39](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/types.ts#L39)* ___ @@ -81,7 +81,7 @@ ___ **ΤWithTheme**: * [ResponsiveObject](_types_.md#responsiveobject)<`P`, `B`> & [ThemeWithBreakpoints](_types_.md#themewithbreakpoints)<`T`, `B`> * -*Defined in [types.ts:43](https://github.com/johanneslumpe/styled-props/blob/892c9ca/src/types.ts#L43)* +*Defined in [types.ts:43](https://github.com/johanneslumpe/styled-props/blob/86dd9fd/src/types.ts#L43)* ___