ketekny-ui-kit 1.0.104 → 1.0.105

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "ketekny-ui-kit",
3
3
  "type": "module",
4
- "version": "1.0.104",
4
+ "version": "1.0.105",
5
5
  "description": "A Vue 3 UI component library with Tailwind CSS styling",
6
6
  "main": "index.js",
7
7
  "files": [
@@ -10,7 +10,10 @@
10
10
  </div>
11
11
  </div>
12
12
 
13
- <section class="bg-white px-4 pb-4 pb-0 pt-8 sm:px-6 lg:px-8">
13
+ <section
14
+ v-if="hasTopSection"
15
+ class="bg-white px-4 pb-4 pb-0 pt-8 sm:px-6 lg:px-8"
16
+ >
14
17
  <div class="mx-auto flex w-full max-w-none flex-col gap-5">
15
18
  <div
16
19
  v-if="pageTitle || pageDescription"
@@ -93,6 +96,14 @@ export default {
93
96
  },
94
97
  },
95
98
  computed: {
99
+ hasTopSection() {
100
+ return Boolean(
101
+ this.pageTitle ||
102
+ this.pageDescription ||
103
+ this.externalUrl ||
104
+ this.$slots['header-actions']
105
+ )
106
+ },
96
107
  showHeaderExtraBeforeTitle() {
97
108
  return this.headerExtraBeforeTitle && Boolean(this.$slots['header-extra'])
98
109
  },
@@ -1,6 +1,9 @@
1
1
  <template>
2
2
  <main class="flex h-screen w-full max-w-none flex-col overflow-hidden bg-slate-100">
3
- <section class="shrink-0 bg-white px-4 pb-4 pb-0 pt-8 sm:px-6 lg:px-8">
3
+ <section
4
+ v-if="hasTopSection"
5
+ class="shrink-0 bg-white px-4 pb-4 pb-0 pt-8 sm:px-6 lg:px-8"
6
+ >
4
7
  <div class="mx-auto flex w-full max-w-none flex-col gap-5">
5
8
  <div
6
9
  v-if="pageTitle || pageDescription"
@@ -31,7 +34,10 @@
31
34
  </div>
32
35
  </section>
33
36
 
34
- <div class="shrink-0 border-b border-t border-slate-200 bg-slate-50 px-4 backdrop-blur">
37
+ <div
38
+ v-if="$slots['header-extra']"
39
+ class="shrink-0 border-b border-t border-slate-200 bg-slate-50 px-4 backdrop-blur"
40
+ >
35
41
  <div class="mx-auto flex w-full max-w-none items-center">
36
42
  <slot name="header-extra" />
37
43
  </div>
@@ -80,6 +86,14 @@ export default {
80
86
  },
81
87
  },
82
88
  computed: {
89
+ hasTopSection() {
90
+ return Boolean(
91
+ this.pageTitle ||
92
+ this.pageDescription ||
93
+ this.externalUrl ||
94
+ this.$slots['header-actions']
95
+ )
96
+ },
83
97
  externalUrlLabel() {
84
98
  const target = String(this.externalUrl || '').trim()
85
99
  if (!target) return ''
@@ -470,6 +470,10 @@ export default {
470
470
  </div>
471
471
  </div>
472
472
 
473
+ <div v-if="$slots['sidebar-header']" :class="collapsed ? 'px-2 pb-2' : 'px-4 pb-3'">
474
+ <slot name="sidebar-header" />
475
+ </div>
476
+
473
477
  <nav
474
478
  class="flex-1 px-3 py-2"
475
479
  :class="collapsed ? 'overflow-visible' : 'overflow-y-auto'"
@@ -20,7 +20,11 @@
20
20
  @edit-profile="handleEditProfile"
21
21
  @item-click="handleItemClick"
22
22
  @select="handleSelect"
23
- />
23
+ >
24
+ <template v-if="$slots['sidebar-header']" #sidebar-header>
25
+ <slot name="sidebar-header" />
26
+ </template>
27
+ </MultilevelSidebar>
24
28
 
25
29
  <main class="flex min-h-0 flex-1 flex-col overflow-y-auto">
26
30
  <div