Skip to content

Commit

Permalink
feat!: release v1 (#56)
Browse files Browse the repository at this point in the history
Co-authored-by: Yaël Guilloux <yael.guilloux@gmail.com>
  • Loading branch information
bdrtsky and Tahul authored Jun 19, 2023
1 parent 29c802f commit fc3a1e0
Show file tree
Hide file tree
Showing 29 changed files with 3,403 additions and 4,381 deletions.
8 changes: 4 additions & 4 deletions .demo/app.vue
Original file line number Diff line number Diff line change
Expand Up @@ -41,14 +41,14 @@ css({
padding: '{space.2}',
alignItems: 'center',
cursor: 'pointer',
color: '{color.gray.600}',
color: '{typography.color.secondary.600}',
'@dark': {
color: '{color.gray.400}'
color: '{typography.color.secondary.400}'
},
'&:hover': {
color: '{color.gray.900}',
color: '{typography.color.secondary.900}',
'@dark': {
color: '{color.gray.100}'
color: '{typography.color.secondary.100}'
}
}
}
Expand Down
9 changes: 5 additions & 4 deletions components/ProseCodeCopyButton.vue
Original file line number Diff line number Diff line change
Expand Up @@ -60,14 +60,15 @@ css({
transform: "scale(0.75)",
opacity: 0,
'&:hover': {
backgroundColor: '{elements.surface.secondary.backgroundColor}',
},
// TODO: handle surface tokens
// '&:hover': {
// backgroundColor: '{elements.surface.secondary.backgroundColor}',
// },
'&:focus': {
opacity: 1,
outline: 'none',
boxShadow: '0 0 0 2px {color.blue.500}',
boxShadow: '0 0 0 2px {typography.color.primary.500}',
},
'&.show': {
Expand Down
13 changes: 1 addition & 12 deletions components/global/ProseA.vue
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ defineProps({
</script>

<template>
<NuxtLink :to="href" :target="target">
<NuxtLink :to="href" :target="target" class="prose-a">
<slot />
</NuxtLink>
</template>
Expand All @@ -39,19 +39,8 @@ css({
},
'&:has(code)': {
borderBottom: '{prose.a.hasCode.borderBottom}',
':deep(code)': {
color: '{prose.a.code.color.static}',
borderWidth: '{prose.a.code.border.width}',
borderStyle: '{prose.a.code.border.style}',
borderColor: '{prose.a.code.border.color.static}',
},
'&:hover': {
borderBottom: '{prose.a.hasCode.borderBottom}',
':deep(code)': {
color: '{prose.a.code.color.hover}',
borderColor: '{prose.a.code.border.color.hover}',
backgroundColor: '{prose.a.code.background.hover}',
},
},
},
},
Expand Down
2 changes: 1 addition & 1 deletion components/global/ProseBlockquote.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<blockquote>
<blockquote class="prose-blockquote">
<slot />
</blockquote>
</template>
Expand Down
18 changes: 9 additions & 9 deletions components/global/ProseCode.vue
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,10 @@ css({
width: "100%",
fontSize: '{prose.code.block.fontSize}',
margin: '{prose.code.block.margin}',
borderRadius: '{radii.md}',
borderWidth: '{prose.code.block.border.width}',
borderStyle: '{prose.code.block.border.style}',
borderColor: '{prose.code.block.border.color}',
borderRadius: '{prose.code.block.borderRadius}',
borderWidth: '{prose.code.block.borderWidth}',
borderStyle: '{prose.code.block.borderStyle}',
borderColor: '{prose.code.block.borderColor}',
color: '{prose.code.block.color}',
backgroundColor: '{prose.code.block.backgroundColor}',
backdropFilter: '{prose.code.block.backdropFilter}',
Expand All @@ -71,7 +71,7 @@ css({
userSelect: "none",
fontWeight: 700,
color: '{typography.color.primary.500}',
fontFamily: '{font.mono}'
fontFamily: '{typography.font.mono}'
}
}
}
Expand All @@ -94,9 +94,9 @@ css({
padding: '0.5rem 0.75rem',
fontFamily: '{typography.font.code}',
color: '{prose.code.block.color}',
borderRadius: '{radii.lg}',
fontSize: '{fontSize.xs}',
lineHeight: '{lead.normal}',
borderRadius: '{typography.radii.lg}',
fontSize: '{typography.fontSize.xs}',
lineHeight: '{typography.lead.normal}',
transition: 'opacity 200ms',
backdropFilter: 'blur(4px)',
},
Expand All @@ -113,7 +113,7 @@ css({
overflowX: "auto",
margin: "0",
padding: '{prose.code.block.pre.padding}',
lineHeight: '{lead.relaxed}',
lineHeight: '{typography.lead.relaxed}',
},
":deep(pre code)": {
paddingInlineEnd: '30px',
Expand Down
17 changes: 14 additions & 3 deletions components/global/ProseCodeInline.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<code>
<code class="prose-code-inline">
<slot />
</code>
</template>
Expand All @@ -21,11 +21,22 @@ css({
},
'h1, h2, h3, h4, h5, h6': {
'a code': {
color: "inherit",
color: '{prose.code.inline.color}',
fontSize: "0.777777em",
borderRadius: "{prose.code.inline.borderRadius}",
padding: "0.15em 0.5em",
}
}
},
'a code': {
color: '{prose.a.code.color.static}',
borderWidth: '{prose.a.code.border.width}',
borderStyle: '{prose.a.code.border.style}',
borderColor: '{prose.a.code.border.color.static}',
},
'a:hover code': {
color: '{prose.a.code.color.hover}',
borderColor: '{prose.a.code.border.color.hover}',
backgroundColor: '{prose.a.code.background.hover}',
},
})
</style>
2 changes: 1 addition & 1 deletion components/global/ProseEm.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<em>
<em class="prose-em">
<slot />
</em>
</template>
Expand Down
2 changes: 1 addition & 1 deletion components/global/ProseH1.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const icon = computed(() => prose?.h1?.icon || prose?.headings?.icon)
</script>

<template>
<h1 :id="id">
<h1 :id="id" class="prose-h1">
<NuxtLink :href="`#${id}`">
<slot />
<Icon v-if="hasIcon" :name="icon" />
Expand Down
2 changes: 1 addition & 1 deletion components/global/ProseH2.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const icon = computed(() => prose?.h2?.icon || prose?.headings?.icon)
</script>

<template>
<h2 :id="id">
<h2 :id="id" class="prose-h2">
<NuxtLink :href="`#${id}`">
<slot />
<Icon v-if="hasIcon" :name="icon" />
Expand Down
2 changes: 1 addition & 1 deletion components/global/ProseH3.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const icon = computed(() => prose?.h3?.icon || prose?.headings?.icon)
</script>

<template>
<h3 :id="id">
<h3 :id="id" class="prose-h3">
<NuxtLink :href="`#${id}`">
<slot />
<Icon v-if="hasIcon" :name="icon" />
Expand Down
2 changes: 1 addition & 1 deletion components/global/ProseH4.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const icon = computed(() => prose?.h4?.icon || prose?.headings?.icon)
</script>

<template>
<h4 :id="id">
<h4 :id="id" class="prose-h4">
<NuxtLink :href="`#${id}`">
<slot />
<Icon v-if="hasIcon" :name="icon" />
Expand Down
2 changes: 1 addition & 1 deletion components/global/ProseH5.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const icon = computed(() => prose?.h5?.icon || prose?.headings?.icon)
</script>

<template>
<h5 :id="id">
<h5 :id="id" class="prose-h5">
<NuxtLink :href="`#${id}`">
<slot />
<Icon v-if="hasIcon" :name="icon" />
Expand Down
2 changes: 1 addition & 1 deletion components/global/ProseH6.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const icon = computed(() => prose?.h6?.icon || prose?.headings?.icon)
</script>

<template>
<h6 :id="id">
<h6 :id="id" class="prose-h6">
<NuxtLink :href="`#${id}`">
<slot />
<Icon v-if="hasIcon" :name="icon" />
Expand Down
2 changes: 1 addition & 1 deletion components/global/ProseHr.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<hr>
<hr class="prose-hr">
</template>

<style lang="ts" scoped>
Expand Down
9 changes: 8 additions & 1 deletion components/global/ProseImg.vue
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,14 @@ const refinedSrc = computed(() => {
</script>

<template>
<img v-bind="$attrs" :src="refinedSrc" :alt="alt" :width="width" :height="height">
<img
v-bind="$attrs"
:src="refinedSrc"
:alt="alt"
:width="width"
:height="height"
class="prose-img"
>
</template>

<style lang="ts" scoped>
Expand Down
4 changes: 3 additions & 1 deletion components/global/ProseLi.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
<template>
<li><slot /></li>
<li class="prose-li">
<slot />
</li>
</template>

<style lang="ts" scoped>
Expand Down
2 changes: 1 addition & 1 deletion components/global/ProseOl.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<ol>
<ol class="prose-ol">
<slot />
</ol>
</template>
Expand Down
4 changes: 3 additions & 1 deletion components/global/ProseP.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
<template>
<p><slot /></p>
<p class="prose-p">
<slot />
</p>
</template>

<style lang="ts" scoped>
Expand Down
2 changes: 1 addition & 1 deletion components/global/ProseStrong.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<strong>
<strong class="prose-strong">
<slot />
</strong>
</template>
Expand Down
4 changes: 2 additions & 2 deletions components/global/ProseTable.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<div class="table-wrapper">
<div class="prose-table">
<table>
<slot />
</table>
Expand All @@ -8,7 +8,7 @@

<style lang="ts" scoped>
css({
".table-wrapper": {
".prose-table": {
overflowX: "auto",
maxWidth: "100%",
margin: '{prose.table.margin}'
Expand Down
2 changes: 1 addition & 1 deletion components/global/ProseTbody.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<tbody>
<tbody class="prose-tbody">
<slot />
</tbody>
</template>
2 changes: 1 addition & 1 deletion components/global/ProseTd.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<td>
<td class="prose-td">
<slot />
</td>
</template>
Expand Down
2 changes: 1 addition & 1 deletion components/global/ProseTh.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<th>
<th class="prose-th">
<slot />
</th>
</template>
Expand Down
2 changes: 1 addition & 1 deletion components/global/ProseThead.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<thead>
<thead class="prose-thead">
<slot />
</thead>
</template>
Expand Down
2 changes: 1 addition & 1 deletion components/global/ProseTr.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<tr>
<tr class="prose-tr">
<slot />
</tr>
</template>
Expand Down
2 changes: 1 addition & 1 deletion components/global/ProseUl.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<ul>
<ul class="prose-ul">
<slot />
</ul>
</template>
Expand Down
26 changes: 13 additions & 13 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@nuxt-themes/typography",
"version": "0.11.0",
"version": "1.0.0-beta.1",
"description": "A beautiful typography with a set of prose components to use with Nuxt Content.",
"keywords": [
"nuxt",
Expand Down Expand Up @@ -34,22 +34,22 @@
},
"dependencies": {
"@nuxtjs/color-mode": "^3.2.0",
"nuxt-config-schema": "^0.4.5",
"nuxt-icon": "^0.3.3",
"pinceau": "^0.18.8",
"ufo": "^1.1.1"
"nuxt-config-schema": "^0.4.6",
"nuxt-icon": "^0.4.1",
"pinceau": "^0.19.0",
"ufo": "^1.1.2"
},
"devDependencies": {
"@nuxt-themes/tokens": "^1.9.1",
"@nuxt/content": "2.5.2",
"@nuxt/devtools": "^0.3.1",
"@nuxthq/studio": "^0.9.2",
"@nuxt-themes/tokens": "^2.0.0",
"@nuxt/content": "2.6.0",
"@nuxt/devtools": "^0.5.5",
"@nuxthq/studio": "^0.12.1",
"@nuxtjs/eslint-config-typescript": "^12.0.0",
"eslint": "^8.36.0",
"nuxt": "3.3.2",
"eslint": "^8.41.0",
"nuxt": "3.5.1",
"nuxt-plausible": "^0.1.2",
"release-it": "^15.9.3",
"typescript": "^5.0.2"
"release-it": "^15.10.3",
"typescript": "^5.0.4"
},
"pnpm": {
"peerDependencyRules": {
Expand Down
Loading

1 comment on commit fc3a1e0

@vercel
Copy link

@vercel vercel bot commented on fc3a1e0 Jun 19, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

typography – ./

typography.nuxt.space
typography-nuxtlabs.vercel.app
typography-git-main-nuxtlabs.vercel.app

Please sign in to comment.