forked from extern/homer
Merge pull request #119 from tpansino/feature/custom-card-colors
Feature/custom card colors
This commit is contained in:
commit
bcf0e1bec2
@ -110,7 +110,8 @@ services:
|
||||
subtitle: "Another example"
|
||||
tag: "other"
|
||||
url: "https://www.reddit.com/r/selfhosted/"
|
||||
target: "_blank" # optionnal html a tag target attribute
|
||||
target: "_blank" # optional html a tag target attribute
|
||||
# class: "green" # optional custom CSS class for card, useful with custom stylesheet
|
||||
```
|
||||
|
||||
If you choose to fetch message information from an endpoint, the output format should be:
|
||||
|
9
public/assets/custom.css.sample
Normal file
9
public/assets/custom.css.sample
Normal file
@ -0,0 +1,9 @@
|
||||
@charset "UTF-8";
|
||||
|
||||
/* Custom card colors */
|
||||
/* Use with `class:` property of services in config.yml */
|
||||
body #app .card .green
|
||||
{
|
||||
background-color: #006600;
|
||||
color: #00ff00;
|
||||
}
|
@ -2,7 +2,10 @@
|
||||
<div>
|
||||
<div class="card">
|
||||
<a :href="item.url" :target="item.target" rel="noreferrer">
|
||||
<div class="card-content">
|
||||
<div
|
||||
class="card-content"
|
||||
:class="item.class"
|
||||
>
|
||||
<div class="media">
|
||||
<div v-if="item.logo" class="media-left">
|
||||
<figure class="image is-48x48">
|
||||
@ -15,8 +18,14 @@
|
||||
</figure>
|
||||
</div>
|
||||
<div class="media-content">
|
||||
<p class="title is-4">{{ item.name }}</p>
|
||||
<p class="subtitle is-6">{{ item.subtitle }}</p>
|
||||
<p
|
||||
class="title is-4"
|
||||
:class="item.class"
|
||||
>{{ item.name }}</p>
|
||||
<p
|
||||
class="subtitle is-6"
|
||||
:class="item.class"
|
||||
>{{ item.subtitle }}</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="tag" :class="item.tagstyle" v-if="item.tag">
|
||||
|
Loading…
Reference in New Issue
Block a user