Skip to content
This repository was archived by the owner on Jun 27, 2024. It is now read-only.

Commit a7cb027

Browse files
committed
WIP
1 parent 014f2ce commit a7cb027

File tree

3 files changed

+10
-2
lines changed

3 files changed

+10
-2
lines changed

js/Components/ButtonWithDropdown.vue

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
<button
55
ref="button"
66
type="button"
7+
:dusk="dusk"
78
:disabled="disabled"
89
class="w-full bg-white border rounded-md shadow-sm px-4 py-2 inline-flex justify-center text-sm font-medium text-gray-700 hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500"
910
:class="{'border-green-300': active, 'border-gray-300': !active, 'cursor-not-allowed': disabled }"
@@ -46,6 +47,12 @@ const props = defineProps({
4647
required: false,
4748
},
4849
50+
dusk: {
51+
type: String,
52+
default: null,
53+
required: false,
54+
},
55+
4956
disabled: {
5057
type: Boolean,
5158
default: false,

js/Components/Table.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<fieldset
33
:key="`table-${name}`"
44
:class="{'opacity-75': isVisiting}"
5-
:disabled="isVisiting"
5+
:disabled="preventOverlappingRequests && isVisiting"
66
>
77
<div class="flex space-x-4">
88
<slot

js/Components/TableColumns.vue

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
<template>
22
<ButtonWithDropdown
33
placement="bottom-end"
4+
dusk="columns-dropdown"
45
:active="hasHiddenColumns"
56
>
67
<template #button>
@@ -72,6 +73,7 @@
7273
:aria-pressed="!column.hidden"
7374
:aria-labelledby="`toggle-column-${column.key}`"
7475
:aria-describedby="`toggle-column-${column.key}`"
76+
:dusk="`toggle-column-${column.key}`"
7577
@click.prevent="onChange(column.key, column.hidden)"
7678
>
7779
<span class="sr-only">Column status</span>
@@ -129,5 +131,4 @@ function oneVisibleFilterLeft() {
129131
return !column.hidden;
130132
}).length === 1;
131133
}
132-
133134
</script>

0 commit comments

Comments
 (0)