implementado tema azul
This commit is contained in:
parent
b4394aacd8
commit
8a6a499b60
13 changed files with 2830 additions and 2362 deletions
|
|
@ -6,7 +6,23 @@
|
|||
<!-- Seção de Componentes -->
|
||||
<div style="flex: 1; min-width: 0; overflow-y: auto;">
|
||||
<v-container class="py-6">
|
||||
<h1 class="text-h5 mb-4">Playground — eli-vue</h1>
|
||||
<div class="d-flex align-center justify-space-between mb-4">
|
||||
<h1 class="text-h5">Playground — eli-vue</h1>
|
||||
<v-btn-toggle
|
||||
v-model="temaAtual"
|
||||
mandatory
|
||||
density="compact"
|
||||
color="primary"
|
||||
@update:model-value="alternarTema"
|
||||
>
|
||||
<v-btn value="verde" prepend-icon="mdi-leaf" size="small">
|
||||
Verde (e-licencie)
|
||||
</v-btn>
|
||||
<v-btn value="azul" prepend-icon="mdi-water" size="small">
|
||||
Azul (Betha)
|
||||
</v-btn>
|
||||
</v-btn-toggle>
|
||||
</div>
|
||||
|
||||
<v-tabs v-model="aba" color="primary" density="comfortable">
|
||||
<v-tab value="botao">Botão</v-tab>
|
||||
|
|
@ -76,7 +92,9 @@
|
|||
|
||||
<script lang="ts">
|
||||
import { defineComponent, provide, ref } from "vue"
|
||||
import { useTheme } from "vuetify"
|
||||
import { EliFeedbackWidget } from "../componentes/FeedbackWidget"
|
||||
import { definirTemaAplicacao, type TipoTemaAplicacao } from "../temas"
|
||||
import BotaoPlayground from "./botao.playground.vue"
|
||||
import CartaoPlayground from "./cartao.playground.vue"
|
||||
import DataHoraPlayground from "./data_hora.playground.vue"
|
||||
|
|
@ -147,9 +165,20 @@ export default defineComponent({
|
|||
const consoleApi: PlaygroundConsole = { adicionarLog, logMensagem }
|
||||
provide(PLAYGROUND_CONSOLE_KEY, consoleApi)
|
||||
|
||||
const theme = useTheme()
|
||||
const temaAtual = ref<TipoTemaAplicacao>("verde")
|
||||
|
||||
function alternarTema(novoTema: TipoTemaAplicacao) {
|
||||
temaAtual.value = novoTema
|
||||
definirTemaAplicacao(novoTema, { vuetify: { theme } })
|
||||
logMensagem(`🎨 Tema alterado para: ${novoTema}`)
|
||||
}
|
||||
|
||||
return {
|
||||
logsConsole,
|
||||
aba: ref<AbaPlayground>("botao"),
|
||||
temaAtual,
|
||||
alternarTema,
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue