@zhangt58/svelte-vtable 0.4.2 → 0.4.3
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.
|
@@ -193,9 +193,11 @@
|
|
|
193
193
|
</script>
|
|
194
194
|
|
|
195
195
|
<div class="w-full">
|
|
196
|
-
|
|
196
|
+
<!-- Search, range and per-page sit together on the left; pagination is
|
|
197
|
+
pushed to the right and wraps below on narrow widths. -->
|
|
198
|
+
<div class="flex flex-wrap items-center w-full gap-x-3 gap-y-1 px-0 py-0">
|
|
197
199
|
<!-- Search field on the left -->
|
|
198
|
-
<div class="
|
|
200
|
+
<div class="min-w-0">
|
|
199
201
|
<div class="flex items-center gap-2">
|
|
200
202
|
<!-- Styled button to open/close filters modal -->
|
|
201
203
|
{#if showFilters}
|
|
@@ -242,7 +244,7 @@
|
|
|
242
244
|
</div>
|
|
243
245
|
{/if}
|
|
244
246
|
|
|
245
|
-
<div class="vtable-search-wrapper relative flex items-center">
|
|
247
|
+
<div class="vtable-search-wrapper relative flex items-center w-64 max-w-full">
|
|
246
248
|
<svg
|
|
247
249
|
class="absolute left-3 h-4 w-4 text-gray-400 pointer-events-none"
|
|
248
250
|
xmlns="http://www.w3.org/2000/svg"
|
|
@@ -298,9 +300,9 @@
|
|
|
298
300
|
</div>
|
|
299
301
|
|
|
300
302
|
<!-- Range count badge + per-page selector -->
|
|
301
|
-
<div class="flex-
|
|
303
|
+
<div class="flex shrink-0 items-center gap-2">
|
|
302
304
|
<span
|
|
303
|
-
class="inline-flex items-center px-2.5 py-0.5 rounded-full text-xs font-medium bg-gray-100 text-gray-800 dark:bg-gray-700 dark:text-gray-200 whitespace-nowrap"
|
|
305
|
+
class="inline-flex items-center px-2.5 py-0.5 rounded-full text-xs font-medium tabular-nums bg-gray-100 text-gray-800 dark:bg-gray-700 dark:text-gray-200 whitespace-nowrap"
|
|
304
306
|
>
|
|
305
307
|
Showing {startItem} to {endItem} of {totalItems}
|
|
306
308
|
</span>
|
|
@@ -309,6 +311,7 @@
|
|
|
309
311
|
<div class="flex items-center gap-2">
|
|
310
312
|
<select
|
|
311
313
|
id={perPageSelectId}
|
|
314
|
+
aria-label="Rows per page"
|
|
312
315
|
class="vtable-perpage-select py-1 pl-3 pr-7 text-sm rounded-md border border-gray-300 bg-white dark:bg-gray-700 dark:border-gray-600 dark:text-gray-100"
|
|
313
316
|
bind:value={perPage}
|
|
314
317
|
>
|
|
@@ -320,7 +323,9 @@
|
|
|
320
323
|
</div>
|
|
321
324
|
|
|
322
325
|
<!-- Pagination navigation -->
|
|
323
|
-
<
|
|
326
|
+
<div class="ml-auto shrink-0">
|
|
327
|
+
<PaginationBar {pages} {currentPage} onpage={goTo} />
|
|
328
|
+
</div>
|
|
324
329
|
</div>
|
|
325
330
|
</div>
|
|
326
331
|
|