WIP
This commit is contained in:
22
resources/views/components/drawer.blade.php
Normal file
22
resources/views/components/drawer.blade.php
Normal file
@@ -0,0 +1,22 @@
|
||||
<template x-teleport="body">
|
||||
<div
|
||||
id="drawer-{{ $name }}"
|
||||
tabindex="-1"
|
||||
class="fixed z-40 w-full overflow-y-auto bg-white border-t border-gray-200 rounded-t-lg dark:border-gray-700 dark:bg-gray-800 transition-transform left-0 right-0 bottom-0"
|
||||
aria-labelledby="drawer-{{ $name }}"
|
||||
x-data="{ show: false }"
|
||||
@drawer-open-{{ $name }}.window="show = true"
|
||||
@drawer-close-{{ $name }}.window="show = false"
|
||||
:class="{ 'translate-y-full': !show }"
|
||||
x-cloak
|
||||
>
|
||||
<div class="p-4 cursor-pointer hover:bg-gray-50 dark:hover:bg-gray-700" @click="show = false">
|
||||
<span class="absolute w-8 h-1 -translate-x-1/2 bg-gray-300 rounded-lg top-3 left-1/2 dark:bg-gray-600">
|
||||
</span>
|
||||
<h5 class="inline-flex items-center text-base text-gray-500 dark:text-gray-400 font-medium">
|
||||
{{ $title }}
|
||||
</h5>
|
||||
</div>
|
||||
{{ $content }}
|
||||
</div>
|
||||
</template>
|
||||
Reference in New Issue
Block a user