2018-06-14 07:52:37 +02:00
|
|
|
<template>
|
2018-06-14 09:48:49 +02:00
|
|
|
<div class="ui-card">
|
2018-06-14 07:52:37 +02:00
|
|
|
<header>
|
|
|
|
<slot name="title"></slot>
|
|
|
|
</header>
|
|
|
|
|
|
|
|
<slot></slot>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script lang="ts">
|
|
|
|
import Vue from 'vue';
|
2018-06-14 11:53:02 +02:00
|
|
|
export default Vue.extend({
|
|
|
|
provide() {
|
|
|
|
return {
|
|
|
|
isCardChild: true
|
|
|
|
};
|
|
|
|
}
|
|
|
|
});
|
2018-06-14 07:52:37 +02:00
|
|
|
</script>
|
|
|
|
|
|
|
|
<style lang="stylus" scoped>
|
|
|
|
@import '~const.styl'
|
|
|
|
|
2018-06-14 14:38:39 +02:00
|
|
|
root(isDark)
|
2018-06-14 11:53:02 +02:00
|
|
|
margin 16px
|
|
|
|
padding 16px
|
2018-06-14 14:38:39 +02:00
|
|
|
background isDark ? #282C37 : #fff
|
2018-06-14 11:53:02 +02:00
|
|
|
box-shadow 0 3px 1px -2px rgba(#000, 0.2), 0 2px 2px 0 rgba(#000, 0.14), 0 1px 5px 0 rgba(#000, 0.12)
|
2018-06-14 09:48:49 +02:00
|
|
|
|
2018-06-14 07:52:37 +02:00
|
|
|
> header
|
2018-06-14 14:38:39 +02:00
|
|
|
font-weight normal
|
|
|
|
font-size 24px
|
|
|
|
color isDark ? #fff : #444
|
|
|
|
|
|
|
|
.ui-card[data-darkmode]
|
|
|
|
root(true)
|
|
|
|
|
|
|
|
.ui-card:not([data-darkmode])
|
|
|
|
root(false)
|
2018-06-14 07:52:37 +02:00
|
|
|
|
|
|
|
</style>
|