Skip to content

Commit

Permalink
feat(Mark): config redesign and implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
driss-chelouati committed Dec 8, 2023
1 parent 0fa7012 commit e4552b4
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 6 deletions.
6 changes: 4 additions & 2 deletions src/plugins/components/mark/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,10 @@ export default plugin.withOptions(

addComponents({
[`.${prefix}mark`]: {
[`@apply bg-${config.bg} dark:bg-${config.bgDark}`]: {},
[`@apply text-${config.text} dark:text-${config.textDark}`]: {},
[`@apply bg-${config.background.light} dark:bg-${config.background.dark}`]:
{},
[`@apply text-${config.color.light} dark:text-${config.color.dark}`]:
{},
},
})
}
Expand Down
12 changes: 8 additions & 4 deletions src/plugins/components/mark/mark.config.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
export const key = 'mark' as const

export const defaultConfig = {
bg: 'primary-100',
bgDark: 'primary-800',
text: 'primary-800',
textDark: 'primary-200',
background: {
light: 'primary-100',
dark: 'primary-800',
},
color: {
light: 'primary-800',
dark: 'primary-200',
},
}

export type MarkConfig = typeof defaultConfig
Expand Down

0 comments on commit e4552b4

Please sign in to comment.