From 76f9894308e5416fe0c8669ef9b422d4349aaf82 Mon Sep 17 00:00:00 2001 From: Cagatay Civici Date: Wed, 9 Oct 2024 11:14:30 +0300 Subject: [PATCH] Add chip and avatar --- assets/styles/presets/aura/avatar.css | 50 +++++++++++++++++++++++ assets/styles/presets/aura/chip.css | 27 ++++++++++++ assets/styles/presets/aura/components.css | 4 ++ 3 files changed, 81 insertions(+) create mode 100644 assets/styles/presets/aura/avatar.css create mode 100644 assets/styles/presets/aura/chip.css diff --git a/assets/styles/presets/aura/avatar.css b/assets/styles/presets/aura/avatar.css new file mode 100644 index 00000000..dd2fd4ad --- /dev/null +++ b/assets/styles/presets/aura/avatar.css @@ -0,0 +1,50 @@ +.p-avatar { + @apply inline-flex items-center justify-center + w-8 h-8 text-base rounded-md + bg-surface-200 dark:bg-surface-700 +} + +.p-avatar-image { + @apply bg-transparent +} + +.p-avatar-circle, +.p-avatar-circle img { + @apply rounded-full +} + +.p-avatar-icon { + @apply text-base +} + +.p-avatar img { + @apply w-full h-full +} + +.p-avatar-lg { + @apply w-12 h-12 text-2xl +} + +.p-avatar-lg .p-avatar-icon { + @apply text-2xl +} + +.p-avatar-xl { + @apply w-16 h-16 text-[2rem] +} + +.p-avatar-xl .p-avatar-icon { + @apply text-[2rem] +} + +.p-avatar-group { + @apply flex items-center +} + +.p-avatar-group .p-avatar + .p-avatar { + @apply -ml-4 +} + +.p-avatar-group .p-avatar { + @apply border-2 border-surface-200 dark:border-surface-700 +} \ No newline at end of file diff --git a/assets/styles/presets/aura/chip.css b/assets/styles/presets/aura/chip.css new file mode 100644 index 00000000..600bba0d --- /dev/null +++ b/assets/styles/presets/aura/chip.css @@ -0,0 +1,27 @@ +.p-chip { + @apply inline-flex items-center rounded-2xl gap-2 px-3 py-2 + bg-surface-100 dark:bg-surface-800 + text-surface-800 dark:text-surface-0 +} + +.p-chip-icon { + @apply text-surface-800 dark:bg-surface-0 text-base w-4 h-4 +} + +.p-chip-image { + @apply rounded-full w-8 h-8 -ml-2 +} + +.p-chip:has(.p-chip-remove-icon) { + @apply pr-2 +} + +.p-chip:has(.p-chip-image) { + @apply pt-1 pb-1 +} + +.p-chip-remove-icon { + @apply cursor-pointer text-base w-4 h-4 rounded-full + text-surface-800 dark:text-surface-0 + focus-visible:outline focus-visible:outline-1 focus-visible:outline-offset-2 focus-visible:outline-primary +} \ No newline at end of file diff --git a/assets/styles/presets/aura/components.css b/assets/styles/presets/aura/components.css index b2786eb8..4d966999 100644 --- a/assets/styles/presets/aura/components.css +++ b/assets/styles/presets/aura/components.css @@ -20,3 +20,7 @@ @import './scrollpanel'; @import './splitter'; @import './toolbar'; + +/* Misc */ +@import './avatar'; +@import './chip';