docs(note): document custom properties

references #14850
This commit is contained in:
Cam Wiegert
2018-08-30 13:50:39 -05:00
parent 0f9a7b4252
commit 88ab4f9ee5
3 changed files with 20 additions and 0 deletions

View File

@ -4,6 +4,10 @@
// -------------------------------------------------- // --------------------------------------------------
:host { :host {
/**
* @prop --color: Color of the note
*/
color: var(--color); color: var(--color);
font-family: $font-family-base; font-family: $font-family-base;

View File

@ -14,6 +14,13 @@ Notes are text elements generally used as subtitles that provide more informatio
| `mode` | `mode` | The mode determines which platform styles to use. Possible values are: `"ios"` or `"md"`. | `Mode` | | `mode` | `mode` | The mode determines which platform styles to use. Possible values are: `"ios"` or `"md"`. | `Mode` |
## CSS Custom Properties
| Name | Description |
| --------- | ----------------- |
| `--color` | Color of the note |
---------------------------------------------- ----------------------------------------------
*Built with [StencilJS](https://stenciljs.com/)* *Built with [StencilJS](https://stenciljs.com/)*

View File

@ -13,6 +13,9 @@
<!-- Default --> <!-- Default -->
<ion-note>Default Note</ion-note> <ion-note>Default Note</ion-note>
<!-- Custom -->
<ion-note class="custom">Custom Note</ion-note>
<!-- Colors --> <!-- Colors -->
<ion-note color="primary">Primary Note</ion-note> <ion-note color="primary">Primary Note</ion-note>
<ion-note color="secondary">Secondary Note</ion-note> <ion-note color="secondary">Secondary Note</ion-note>
@ -36,5 +39,11 @@
<ion-label>Note (Start)</ion-label> <ion-label>Note (Start)</ion-label>
</ion-item> </ion-item>
</ion-list> </ion-list>
<style>
.custom {
--color: hotpink;
}
</style>
</body> </body>
</html> </html>