|
| 1 | +# DeckDeckGo - Extra Components |
| 2 | + |
| 3 | +[DeckDeckGo] provide a couple of extra components which could be use in any slides of your presentation. |
| 4 | + |
| 5 | +## Table of contents |
| 6 | + |
| 7 | +- [Social](#social) |
| 8 | + |
| 9 | +## Social |
| 10 | + |
| 11 | +The "Social" component allows you to easily add a social link to your presentation. |
| 12 | + |
| 13 | +### Usage |
| 14 | + |
| 15 | +The "Social" slide's Web Component could be integrated using the tag `<deckgo-social/>`. |
| 16 | + |
| 17 | +``` |
| 18 | +<deckgo-social twitter="daviddalbusco"> |
| 19 | + <img data-src="/assets/twitter.svg" slot="icon"/> |
| 20 | + twitter |
| 21 | +</deckgo-social> |
| 22 | +``` |
| 23 | + |
| 24 | +#### Slots |
| 25 | + |
| 26 | +The slot `icon` and the text are both optional. Of course, if you provide nothing, nothing will be rendered. |
| 27 | + |
| 28 | +### Attributes |
| 29 | + |
| 30 | +This component offers the following options which could be set using attributes: |
| 31 | + |
| 32 | +| Attribute | Type | Default | Description | |
| 33 | +| -------------------------- |:-----------------:|:-----------------:|:-----------------:| |
| 34 | +| twitter | string | | Your Twitter username. It will be concatenated automatically with `https://twitter.com/` | |
| 35 | +| linkedin | string | | Your Linkedin username. It will be concatenated automatically with `https://www.linkedin.com/in/` | |
| 36 | +| medium | string | | Your Medium username. It will be concatenated automatically with `https://medium.com/@` | |
| 37 | +| github | string | | Your Github username. It will be concatenated automatically with `https://github.com/` | |
| 38 | +| fullUrl | string | | In case you would like to provide the URI of your choice | |
| 39 | + |
| 40 | +### Examples |
| 41 | + |
| 42 | +Without any icons: |
| 43 | + |
| 44 | +``` |
| 45 | +<deckgo-social twitter="daviddalbusco">Twitter</deckgo-social> |
| 46 | +<deckgo-social linkedin="david-dal-busco/">Linkedin</deckgo-social> |
| 47 | +<deckgo-social medium="david.dalbusco">Medium</deckgo-social> |
| 48 | +<deckgo-social full-url="https://stackoverflow.com/users/5404186/peter-parker">Stackoverflow</deckgo-social> |
| 49 | +``` |
| 50 | + |
| 51 | +With for example `ion-icon`: |
| 52 | + |
| 53 | +``` |
| 54 | +<deckgo-social twitter="daviddalbusco"><ion-icon slot="icon" name="logo-twitter"></ion-icon> Twitter</deckgo-social> |
| 55 | +<deckgo-social github="fluster/deckdeckgo"><ion-icon slot="icon" name="logo-github"></ion-icon> DeckDeckGo on Github</deckgo-social> |
| 56 | +``` |
| 57 | + |
| 58 | +[DeckDeckGo]: https://deckdeckgo.com |
0 commit comments