Atelier
Menos pressa. Mais presença. Uma edição editorial com serifas nos títulos e uma fonte de leitura no corpo. Alterne entre edição diurna e noturna: o cartão da citação mantém seu próprio tema e o cabeçalho externo continua independente.
Abra o caderno, preencha o e-mail e confirme a inscrição para explorar Sheet, Dialog e Toast no tema local. O conteúdo é uma demonstração: não há envio, cadastro ou persistência de e-mail. Os dados desaparecem quando a tela é desmontada.
Temas · Tipografia · Text e MSpan
Tema
ts
import {
defineTheme,
mavis,
midnight,
type FontFamily,
type ThemeOptions,
} from '@getcortexlabs/mavis-core'
const editorial: FontFamily = {
web: 'Georgia, "Times New Roman", serif',
ios: 'Georgia',
android: 'serif',
}
const body: FontFamily = {
web: '"Avenir Next", "Segoe UI", sans-serif',
ios: 'Avenir Next',
android: 'sans-serif',
}
const typography: ThemeOptions['typography'] = {
display: {
fontFamily: editorial,
fontSize: 48,
fontWeight: 'normal',
lineHeight: 1.12,
letterSpacing: -0.025,
},
title: { fontFamily: editorial, fontSize: 32, fontWeight: 'normal', lineHeight: 1.2 },
heading: { fontFamily: editorial, fontSize: 23, fontWeight: 'normal', lineHeight: 1.25 },
body: { fontFamily: body, lineHeight: 1.55 },
caption: { fontFamily: body, lineHeight: 1.45 },
overline: { fontFamily: body, fontWeight: '600', letterSpacing: 0.14 },
}
const components: ThemeOptions['components'] = {
button: { radius: 'full', paddingY: 14, fontWeight: '600', lineHeight: 1.35 },
input: { radius: 'sm', fontSize: 17, lineHeight: 1.5, paddingX: 18, paddingY: 16 },
card: { padding: 28, radius: 24, elevation: 'md' },
}
export const atelier = defineTheme(
{
name: 'atelier',
colors: {
background: '#F8F3EC',
surface: '#FFFDF8',
elevated: '#F0E7DF',
text: '#332B37',
muted: '#776673',
primary: '#9E345E',
primarySoft: '#F4DFE7',
border: '#E7DCD5',
},
typography,
components,
},
mavis,
)
export const atelierNight = defineTheme(
{
name: 'atelier-night',
colors: {
background: '#211B25',
surface: '#2C2331',
elevated: '#3B2C3C',
text: '#FAF0E5',
muted: '#C7B4BE',
primary: '#EEAFC8',
onPrimary: '#3B1729',
primarySoft: '#4A2B40',
border: '#57424F',
},
typography,
components,
elevation: { md: { color: 'rgba(0, 0, 0, 0.3)' } },
},
midnight,
)Composição
vue
<script setup lang="ts">
import { useCatalogLocale } from '../locale'
import { ref } from 'vue'
import { useMavisTheme, useToast } from '@getcortexlabs/mavis-core/vue'
import { atelierNight } from './theme'
const { t } = useCatalogLocale()
const { theme, setAppearance } = useMavisTheme()
const email = ref('')
const sheet = ref(false)
const dialog = ref(false)
const subscribed = ref(false)
const toast = useToast()
function subscribe() {
subscribed.value = true
dialog.value = false
toast.show({
title: t('Seu lugar está guardado.'),
message: t('Uma boa leitura chega no domingo.'),
tone: 'success',
})
}
</script>
<template>
<m-column
id="studio-edition"
padding="lg"
gap="xl"
radius="lg"
:backgroundColor="theme.colors.background"
>
<m-row justify="between" gap="md" wrap>
<m-text variant="heading" weight="600">{{ t('atelier.') }}</m-text>
<m-button
size="sm"
variant="ghost"
@click="setAppearance(theme.appearance === 'light' ? 'dark' : 'light')"
>
{{ t(theme.appearance === 'light' ? 'Edição noturna' : 'Edição diurna') }}
</m-button>
</m-row>
<m-separator />
<m-row gap="xl" align="start" wrap>
<m-column :width="280" :grow="1" gap="lg" paddingY="md">
<m-text variant="overline" tone="primary">{{ t('UM POUCO DE ESPAÇO PARA VOCÊ') }}</m-text>
<m-text id="studio-headline" as="h1" variant="display"
>{{ t('Menos pressa.') + ' '
}}<m-span emphasis="em" tone="primary">{{ t('Mais presença.') }}</m-span></m-text
>
<m-text tone="muted">{{
t('Histórias, ideias e pequenos rituais para olhar o cotidiano com mais atenção.')
}}</m-text>
<m-row gap="md" wrap>
<m-button @click="sheet = true">{{ t('Conheça a edição') }}</m-button>
<m-text variant="caption" tone="muted">{{ t('Aos domingos. No seu tempo.') }}</m-text>
</m-row>
</m-column>
<m-card id="studio-feature" :width="280" :grow="1" gap="lg">
<m-row justify="between">
<m-text variant="overline" tone="primary">{{ t('CADERNO 01') }}</m-text>
<m-badge :text="t('8 min')" />
</m-row>
<m-column
:height="158"
justify="center"
align="center"
radius="lg"
:backgroundColor="theme.colors.primarySoft"
>
<m-text variant="display" tone="primary">{{ t('Aa.') }}</m-text>
<m-text variant="overline" tone="primary">{{ t('O PRAZER DAS PEQUENAS COISAS') }}</m-text>
</m-column>
<m-text variant="title">{{ t('O que fica quando a gente desacelera?') }}</m-text>
<m-text tone="muted">{{
t('Uma conversa sobre tempo, escolha e a beleza de estar aqui.')
}}</m-text>
<m-button variant="secondary" @click="sheet = true">{{ t('Abrir o caderno') }}</m-button>
</m-card>
</m-row>
<m-row gap="lg" align="start" wrap>
<m-column :width="280" :grow="1" gap="md">
<m-text variant="overline" tone="primary">{{ t('UMA CARTA, NÃO MAIS RUÍDO') }}</m-text>
<m-text variant="heading">{{ t('Um encontro com boas ideias.') }}</m-text>
<m-input
v-model="email"
:label="t('Seu e-mail')"
:placeholder="t('voce@exemplo.com')"
type="email"
autocomplete="email"
name="studio-email"
:helperText="t('Uma carta por semana. Sem pressa, sem excessos.')"
/>
<m-button :disabled="!email.trim() || subscribed" @click="dialog = true">{{
t(subscribed ? 'Você está na lista' : 'Quero receber a carta')
}}</m-button>
</m-column>
<m-theme-provider :theme="atelierNight">
<m-card id="studio-note" :width="280" :grow="1" gap="lg">
<m-text variant="overline" tone="primary">{{ t('PARA LEVAR COM VOCÊ') }}</m-text>
<m-text variant="title"
>{{ t('“A vida acontece ')
}}<m-span emphasis="em" tone="primary">{{ t('nos intervalos.') }}</m-span
>”</m-text
>
<m-text variant="caption" tone="muted">{{
t('Notas de uma manhã sem despertador.')
}}</m-text>
</m-card>
</m-theme-provider>
</m-row>
<m-sheet
v-model:open="sheet"
:title="t('Nesta edição')"
:closeLabel="t('Fechar edição')"
gap="md"
>
<m-text variant="title"
>{{ t('Uma pausa ')
}}<m-span emphasis="em" tone="primary">{{ t('bem-vinda.') }}</m-span></m-text
>
<m-text>{{ t('Três histórias sobre o tempo que escolhemos guardar.') }}</m-text>
<m-text variant="caption" tone="muted">{{
t('01 · Um café sem tela. 02 · A caminhada mais longa. 03 · Uma carta escrita à mão.')
}}</m-text>
<m-button @click="sheet = false">{{ t('Voltar à edição') }}</m-button>
</m-sheet>
<m-dialog
v-model:open="dialog"
:title="t('Um lugar na sua semana')"
:description="t('Podemos guardar este e-mail para a nossa carta de domingo?')"
confirmLabel="Sim, quero receber"
cancelLabel="Agora não"
@confirm="subscribe"
/>
<m-toast :controller="toast" />
</m-column>
</template>