edvoyui-component-library-test-flight 0.0.135 → 0.0.137
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/dist/library-vue-ts.cjs.js +53 -53
- package/dist/library-vue-ts.css +1 -1
- package/dist/library-vue-ts.es.js +9653 -9177
- package/dist/library-vue-ts.umd.js +56 -56
- package/dist/popover/EUIPopover.vue.d.ts +1 -1
- package/dist/table/ColumnResizeTable.vue.d.ts +5 -0
- package/dist/table/ColumnResizeTable.vue.d.ts.map +1 -0
- package/dist/table/GrowthTable.vue.d.ts +1 -1
- package/dist/tooltip/EUITooltip.vue.d.ts +1 -1
- package/package.json +1 -1
- package/src/components/HelloWorld.vue +269 -6
- package/src/components/index.ts +1 -0
- package/src/components/popover/EUIPopover.stories.ts +80 -21
- package/src/components/popover/EUIPopover.vue +171 -43
- package/src/components/table/ColumnResizeTable.vue +733 -0
- package/src/components/table/GrowthTable.vue +4 -3
- package/src/components/table/GrowthTableView.vue +22 -22
- package/src/components/table/ResizeTableview.vue +198 -0
- package/src/components/table/UTableview.vue +6 -1
- package/src/components/tooltip/EUITooltip.vue +6 -3
- package/src/data/table.ts +4 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export * from "/Volumes/work/repos/edvoy-ui-v2/src/components/popover/EUIPopover.vue?vue&type=script&setup=true&lang.ts";
|
|
2
|
-
import "/Volumes/work/repos/edvoy-ui-v2/src/components/popover/EUIPopover.vue?vue&type=style&index=0&scoped=
|
|
2
|
+
import "/Volumes/work/repos/edvoy-ui-v2/src/components/popover/EUIPopover.vue?vue&type=style&index=0&scoped=03588f75&lang.scss";
|
|
3
3
|
declare const _default: any;
|
|
4
4
|
export default _default;
|
|
5
5
|
//# sourceMappingURL=EUIPopover.vue.d.ts.map
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import _sfc_main from "/Volumes/work/repos/edvoy-ui-v2/src/components/table/ColumnResizeTable.vue?vue&type=script&setup=true&lang.ts";
|
|
2
|
+
export * from "/Volumes/work/repos/edvoy-ui-v2/src/components/table/ColumnResizeTable.vue?vue&type=script&setup=true&lang.ts";
|
|
3
|
+
import "/Volumes/work/repos/edvoy-ui-v2/src/components/table/ColumnResizeTable.vue?vue&type=style&index=0&lang.scss";
|
|
4
|
+
export default _sfc_main;
|
|
5
|
+
//# sourceMappingURL=ColumnResizeTable.vue.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ColumnResizeTable.vue.d.ts","sourceRoot":"","sources":["../../src/components/table/ColumnResizeTable.vue"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,+GAA+G,CAAC;AACtI,cAAc,+GAA+G,CAAC;AAC9H,OAAO,6GAA6G,CAAC;AACrH,eAAe,SAAS,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export * from "/Volumes/work/repos/edvoy-ui-v2/src/components/table/GrowthTable.vue?vue&type=script&setup=true&lang.ts";
|
|
2
|
-
import "/Volumes/work/repos/edvoy-ui-v2/src/components/table/GrowthTable.vue?vue&type=style&index=0&scoped=
|
|
2
|
+
import "/Volumes/work/repos/edvoy-ui-v2/src/components/table/GrowthTable.vue?vue&type=style&index=0&scoped=e8f9f620&lang.scss";
|
|
3
3
|
declare const _default: any;
|
|
4
4
|
export default _default;
|
|
5
5
|
//# sourceMappingURL=GrowthTable.vue.d.ts.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export * from "/Volumes/work/repos/edvoy-ui-v2/src/components/tooltip/EUITooltip.vue?vue&type=script&setup=true&lang.ts";
|
|
2
|
-
import "/Volumes/work/repos/edvoy-ui-v2/src/components/tooltip/EUITooltip.vue?vue&type=style&index=0&scoped=
|
|
2
|
+
import "/Volumes/work/repos/edvoy-ui-v2/src/components/tooltip/EUITooltip.vue?vue&type=style&index=0&scoped=45d5b869&lang.scss";
|
|
3
3
|
declare const _default: any;
|
|
4
4
|
export default _default;
|
|
5
5
|
//# sourceMappingURL=EUITooltip.vue.d.ts.map
|
package/package.json
CHANGED
|
@@ -5,22 +5,261 @@
|
|
|
5
5
|
>
|
|
6
6
|
Edvoy User Interface
|
|
7
7
|
</h1>
|
|
8
|
-
|
|
9
|
-
<!-- TODO: Add scroll to tab section in Student details page same -->
|
|
10
|
-
|
|
11
8
|
</div>
|
|
12
9
|
</template>
|
|
13
10
|
<script setup lang="ts">
|
|
14
|
-
|
|
15
11
|
</script>
|
|
16
12
|
<style lang="scss"></style>
|
|
17
13
|
|
|
18
14
|
<!-- Development code here -->
|
|
19
15
|
|
|
20
|
-
|
|
16
|
+
<!-- <template>
|
|
21
17
|
<div class="h-[clac(100svh-64px)] w-full px-10 py-8 max-w-screen-xl mx-auto">
|
|
22
18
|
<h1 class="mb-2 font-semibold text-gray-900 tetx-lg">Edvoy UI Componnet</h1>
|
|
23
19
|
|
|
20
|
+
|
|
21
|
+
<div class="grid w-full h-48 grid-cols-4 gap-4 mb-20 isolate">
|
|
22
|
+
<div
|
|
23
|
+
class="flex items-center justify-between w-full max-w-2xl gap-4 p-2 mx-auto border rounded-lg h-max"
|
|
24
|
+
>
|
|
25
|
+
<div class="text-base font-semibold leading-loose text-gray-900">
|
|
26
|
+
Popover Click Method
|
|
27
|
+
</div>
|
|
28
|
+
|
|
29
|
+
<div class="inline-flex items-center justify-end flex-none gap-4">
|
|
30
|
+
<EUIPopover
|
|
31
|
+
trigger="click"
|
|
32
|
+
placement="bottom-end"
|
|
33
|
+
className="max-w-80 min-w-80"
|
|
34
|
+
customButton="capitalize box-border border-none inline-flex flex-row gap-x-2 items-center active:scale-[.97] active:shadow-md transition duration-150 ease-in-out active:translate-y-0.5 rounded-lg bg-white hover:bg-gray-100 active:bg-gray-50 text-black cursor-pointer active:shadow-white/50 active:bg-transparent text-base font-semibold p-2"
|
|
35
|
+
>
|
|
36
|
+
<template #referenceButton="{ open }">
|
|
37
|
+
<div class="relative">
|
|
38
|
+
<FunnelIcon class="text-current size-6" />
|
|
39
|
+
<div
|
|
40
|
+
v-if="!open"
|
|
41
|
+
class="absolute bg-purple-600 border-2 border-white -top-1 -right-1 rounded-3xl size-3"
|
|
42
|
+
/>
|
|
43
|
+
</div>
|
|
44
|
+
</template>
|
|
45
|
+
|
|
46
|
+
<div
|
|
47
|
+
class="block p-6 bg-white rounded-lg shadow-lg me-2 ring-1 ring-gray-100 ring-opacity-10"
|
|
48
|
+
>
|
|
49
|
+
<div>lorem ipsum dolor sit amet consectetur adipisicing elit.</div>
|
|
50
|
+
<div @click.stop>
|
|
51
|
+
<EUISelect
|
|
52
|
+
search-label="name"
|
|
53
|
+
label="Select Label"
|
|
54
|
+
placeholder="Placeholder"
|
|
55
|
+
:items="datas"
|
|
56
|
+
:multiple="true"
|
|
57
|
+
:multiple-limit="3"
|
|
58
|
+
/>
|
|
59
|
+
</div>
|
|
60
|
+
|
|
61
|
+
<div>lorem ipsum dolor sit amet consectetur adipisicing elit</div>
|
|
62
|
+
<div class="flex items-center justify-end gap-4 pt-4">
|
|
63
|
+
<EUIButton
|
|
64
|
+
type="button"
|
|
65
|
+
size="md"
|
|
66
|
+
color="white"
|
|
67
|
+
:loading="isLoading"
|
|
68
|
+
@click="resetFilters()"
|
|
69
|
+
>Reset</EUIButton
|
|
70
|
+
>
|
|
71
|
+
<EUIButton
|
|
72
|
+
type="button"
|
|
73
|
+
size="md"
|
|
74
|
+
color="purple"
|
|
75
|
+
:loading="isLoading"
|
|
76
|
+
@click="applyFilter()"
|
|
77
|
+
>Apply</EUIButton
|
|
78
|
+
>
|
|
79
|
+
</div>
|
|
80
|
+
</div>
|
|
81
|
+
</EUIPopover>
|
|
82
|
+
</div>
|
|
83
|
+
</div>
|
|
84
|
+
|
|
85
|
+
<div
|
|
86
|
+
class="flex items-center justify-between w-full max-w-2xl gap-4 p-2 mx-auto border rounded-lg h-max"
|
|
87
|
+
>
|
|
88
|
+
<div class="text-base font-semibold leading-loose text-gray-900">
|
|
89
|
+
Popover Hover Method
|
|
90
|
+
</div>
|
|
91
|
+
|
|
92
|
+
<div class="inline-flex items-center justify-end flex-none gap-4">
|
|
93
|
+
<EUIPopover
|
|
94
|
+
trigger="hover"
|
|
95
|
+
placement="bottom-end"
|
|
96
|
+
:hover-hide-delay="150"
|
|
97
|
+
className="max-w-80 min-w-80"
|
|
98
|
+
customButton="capitalize box-border border-none inline-flex flex-row gap-x-2 items-center active:scale-[.97] active:shadow-md transition duration-150 ease-in-out active:translate-y-0.5 rounded-lg bg-white hover:bg-gray-100 active:bg-gray-50 text-black cursor-pointer active:shadow-white/50 active:bg-transparent text-base font-semibold p-2"
|
|
99
|
+
>
|
|
100
|
+
<template #referenceButton>
|
|
101
|
+
<div class="relative">
|
|
102
|
+
<FunnelIcon class="text-current size-6" />
|
|
103
|
+
<div
|
|
104
|
+
class="absolute bg-purple-600 border-2 border-white -top-1 -right-1 rounded-3xl size-3"
|
|
105
|
+
/>
|
|
106
|
+
</div>
|
|
107
|
+
</template>
|
|
108
|
+
<div
|
|
109
|
+
class="block p-6 bg-white rounded-lg shadow-lg me-2 ring-1 ring-gray-100 ring-opacity-10"
|
|
110
|
+
>
|
|
111
|
+
<div>
|
|
112
|
+
Lorem ipsum dolor sit amet consectetur adipisicing elit. Ex atque
|
|
113
|
+
sed illo ipsa tenetur dolores minus quis, impedit aliquam magni.
|
|
114
|
+
Animi laborum tenetur culpa aperiam porro nihil eius soluta
|
|
115
|
+
asperiores.
|
|
116
|
+
</div>
|
|
117
|
+
|
|
118
|
+
<div class="flex items-center justify-end gap-4 pt-4">
|
|
119
|
+
<EUIButton
|
|
120
|
+
type="button"
|
|
121
|
+
size="md"
|
|
122
|
+
color="white"
|
|
123
|
+
:loading="isLoading"
|
|
124
|
+
@click="resetFilters()"
|
|
125
|
+
>Reset</EUIButton
|
|
126
|
+
>
|
|
127
|
+
<EUIButton
|
|
128
|
+
type="button"
|
|
129
|
+
size="md"
|
|
130
|
+
color="purple"
|
|
131
|
+
:loading="isLoading"
|
|
132
|
+
@click="applyFilter()"
|
|
133
|
+
>Apply</EUIButton
|
|
134
|
+
>
|
|
135
|
+
</div>
|
|
136
|
+
</div>
|
|
137
|
+
</EUIPopover>
|
|
138
|
+
</div>
|
|
139
|
+
</div>
|
|
140
|
+
|
|
141
|
+
<div
|
|
142
|
+
class="flex items-center justify-between w-full max-w-2xl gap-4 p-2 mx-auto border rounded-lg h-max"
|
|
143
|
+
>
|
|
144
|
+
<div class="text-base font-semibold leading-loose text-gray-900">
|
|
145
|
+
Popover Default Open
|
|
146
|
+
</div>
|
|
147
|
+
|
|
148
|
+
<div class="inline-flex items-center justify-end flex-none gap-4">
|
|
149
|
+
<EUIPopover
|
|
150
|
+
v-model:visible="isInitiallyOpen"
|
|
151
|
+
placement="bottom-end"
|
|
152
|
+
:hover-hide-delay="150"
|
|
153
|
+
className="max-w-80 min-w-80"
|
|
154
|
+
customButton="capitalize box-border border-none inline-flex flex-row gap-x-2 items-center active:scale-[.97] active:shadow-md transition duration-150 ease-in-out active:translate-y-0.5 rounded-lg bg-white hover:bg-gray-100 active:bg-gray-50 text-black cursor-pointer active:shadow-white/50 active:bg-transparent text-base font-semibold p-2"
|
|
155
|
+
>
|
|
156
|
+
<template #referenceButton>
|
|
157
|
+
<div class="relative">
|
|
158
|
+
<FunnelIcon class="text-current size-6" />
|
|
159
|
+
<div
|
|
160
|
+
class="absolute bg-purple-600 border-2 border-white -top-1 -right-1 rounded-3xl size-3"
|
|
161
|
+
/>
|
|
162
|
+
</div>
|
|
163
|
+
</template>
|
|
164
|
+
<div
|
|
165
|
+
class="block p-6 bg-white rounded-lg shadow-lg me-2 ring-1 ring-gray-100 ring-opacity-10"
|
|
166
|
+
>
|
|
167
|
+
<div>
|
|
168
|
+
Lorem ipsum dolor sit amet consectetur adipisicing elit. Ex atque
|
|
169
|
+
sed illo ipsa tenetur dolores minus quis, impedit aliquam magni.
|
|
170
|
+
Animi laborum tenetur culpa aperiam porro nihil eius soluta
|
|
171
|
+
asperiores.
|
|
172
|
+
</div>
|
|
173
|
+
|
|
174
|
+
<div class="flex items-center justify-end gap-4 pt-4">
|
|
175
|
+
<EUIButton
|
|
176
|
+
type="button"
|
|
177
|
+
size="md"
|
|
178
|
+
color="white"
|
|
179
|
+
:loading="isLoading"
|
|
180
|
+
@click="resetFilters()"
|
|
181
|
+
>Reset</EUIButton
|
|
182
|
+
>
|
|
183
|
+
<EUIButton
|
|
184
|
+
type="button"
|
|
185
|
+
size="md"
|
|
186
|
+
color="purple"
|
|
187
|
+
:loading="isLoading"
|
|
188
|
+
@click="onDefaultClose()"
|
|
189
|
+
>Apply</EUIButton
|
|
190
|
+
>
|
|
191
|
+
</div>
|
|
192
|
+
</div>
|
|
193
|
+
</EUIPopover>
|
|
194
|
+
</div>
|
|
195
|
+
</div>
|
|
196
|
+
|
|
197
|
+
<div
|
|
198
|
+
class="flex items-center justify-between w-full max-w-2xl gap-4 p-2 mx-auto border rounded-lg h-max"
|
|
199
|
+
>
|
|
200
|
+
<div class="text-base font-semibold leading-loose text-gray-900">
|
|
201
|
+
Popover Manual
|
|
202
|
+
</div>
|
|
203
|
+
|
|
204
|
+
<div class="inline-flex items-center justify-end flex-none gap-4">
|
|
205
|
+
<EUIPopover
|
|
206
|
+
trigger="manual"
|
|
207
|
+
v-model:visible="popoverVisible"
|
|
208
|
+
placement="top"
|
|
209
|
+
className="max-w-80 min-w-80"
|
|
210
|
+
customButton="capitalize box-border border-none inline-flex flex-row gap-x-2 items-center active:scale-[.97] active:shadow-md transition duration-150 ease-in-out active:translate-y-0.5 rounded-lg bg-white hover:bg-gray-100 active:bg-gray-50 text-black cursor-pointer active:shadow-white/50 active:bg-transparent text-base font-semibold p-2"
|
|
211
|
+
@click="onPopoverToggle"
|
|
212
|
+
>
|
|
213
|
+
<template #referenceButton>
|
|
214
|
+
<div class="relative">
|
|
215
|
+
<FunnelIcon class="text-current size-6" />
|
|
216
|
+
<div
|
|
217
|
+
class="absolute bg-purple-600 border-2 border-white -top-1 -right-1 rounded-3xl size-3"
|
|
218
|
+
/>
|
|
219
|
+
</div>
|
|
220
|
+
</template>
|
|
221
|
+
<div
|
|
222
|
+
class="block p-6 bg-white rounded-lg shadow-lg me-2 ring-1 ring-gray-100 ring-opacity-10"
|
|
223
|
+
>
|
|
224
|
+
<div>lorem ipsum dolor sit amet consectetur adipisicing elit.</div>
|
|
225
|
+
<div @click.stop>
|
|
226
|
+
<EUISelect
|
|
227
|
+
search-label="name"
|
|
228
|
+
label="Select Label"
|
|
229
|
+
placeholder="Placeholder"
|
|
230
|
+
:items="datas"
|
|
231
|
+
:multiple="true"
|
|
232
|
+
:multiple-limit="3"
|
|
233
|
+
/>
|
|
234
|
+
</div>
|
|
235
|
+
|
|
236
|
+
<div>lorem ipsum dolor sit amet consectetur adipisicing elit</div>
|
|
237
|
+
|
|
238
|
+
<div class="flex items-center justify-end gap-4 pt-4">
|
|
239
|
+
<EUIButton
|
|
240
|
+
type="button"
|
|
241
|
+
size="md"
|
|
242
|
+
color="white"
|
|
243
|
+
:loading="isLoading"
|
|
244
|
+
@click="resetFilters()"
|
|
245
|
+
>Reset</EUIButton
|
|
246
|
+
>
|
|
247
|
+
<EUIButton
|
|
248
|
+
type="button"
|
|
249
|
+
size="md"
|
|
250
|
+
color="purple"
|
|
251
|
+
:loading="isLoading"
|
|
252
|
+
@click="applyFilter()"
|
|
253
|
+
>Apply</EUIButton
|
|
254
|
+
>
|
|
255
|
+
</div>
|
|
256
|
+
</div>
|
|
257
|
+
</EUIPopover>
|
|
258
|
+
</div>
|
|
259
|
+
</div>
|
|
260
|
+
</div>
|
|
261
|
+
|
|
262
|
+
|
|
24
263
|
<div class="mb-10">
|
|
25
264
|
<EUITabOutline
|
|
26
265
|
activeColor="purple"
|
|
@@ -1152,7 +1391,7 @@ import EUIAvatar from "./avatar/EUIAvatar.vue";
|
|
|
1152
1391
|
import EUIStepperTimeline from "./stepperTimeline/EUIStepperTimeline.vue";
|
|
1153
1392
|
import EUIAccordion from "./accordion/EUIAccordion.vue";
|
|
1154
1393
|
import EUITelephone from "./telephone/EUITelephone.vue";
|
|
1155
|
-
import { DevicePhoneMobileIcon, ExclamationTriangleIcon, HomeIcon } from "@heroicons/vue/24/outline";
|
|
1394
|
+
import { DevicePhoneMobileIcon, ExclamationTriangleIcon, FunnelIcon, HomeIcon } from "@heroicons/vue/24/outline";
|
|
1156
1395
|
import EUIDatepicker from "./datepicker/EUIDatepicker.vue";
|
|
1157
1396
|
import EUIDashboardTable from "./table/EUIDashboardTable.vue";
|
|
1158
1397
|
import tabData from "../data/tab";
|
|
@@ -1172,6 +1411,30 @@ import EUIAlerts from "./alerts/EUIAlerts.vue";
|
|
|
1172
1411
|
import EUIButtonGroup from "./button/EUIButtonGroup.vue";
|
|
1173
1412
|
import EUISearchExpand from "./searchexpand/EUISearchExpand.vue";
|
|
1174
1413
|
import EUITabOutline from "./tabs/EUITabOutline.vue";
|
|
1414
|
+
import EUIPopover from "./popover/EUIPopover.vue";
|
|
1415
|
+
|
|
1416
|
+
// TODO: Popover
|
|
1417
|
+
const isLoading = ref(false);
|
|
1418
|
+
const popoverVisible = ref(false);
|
|
1419
|
+
|
|
1420
|
+
const isInitiallyOpen = ref(true);
|
|
1421
|
+
const onDefaultClose = () => {
|
|
1422
|
+
isInitiallyOpen.value = false;
|
|
1423
|
+
};
|
|
1424
|
+
|
|
1425
|
+
const onPopoverToggle = () => {
|
|
1426
|
+
popoverVisible.value = !popoverVisible.value;
|
|
1427
|
+
};
|
|
1428
|
+
|
|
1429
|
+
const onPopoverHide = () => {
|
|
1430
|
+
popoverVisible.value = false;
|
|
1431
|
+
};
|
|
1432
|
+
|
|
1433
|
+
const applyFilter = () => {
|
|
1434
|
+
onPopoverHide();
|
|
1435
|
+
};
|
|
1436
|
+
|
|
1437
|
+
const resetFilters = () => {};
|
|
1175
1438
|
|
|
1176
1439
|
const allDays = ref([
|
|
1177
1440
|
{ name: "7 days", count: 5 },
|
package/src/components/index.ts
CHANGED
|
@@ -41,6 +41,7 @@ export { default as EUITable } from "./table/EUITable.vue";
|
|
|
41
41
|
export { default as EUIStudentPagination } from "./table/EUIStudentPagination.vue";
|
|
42
42
|
export { default as EUIMultiDropdown } from "./dropdown/EUIMultiDropdown.vue";
|
|
43
43
|
export { default as GrowthTable } from "./table/GrowthTable.vue";
|
|
44
|
+
export { default as ColumnResizeTable } from "./table/ColumnResizeTable.vue";
|
|
44
45
|
|
|
45
46
|
export { default as EUILoader } from "./loader/EUILoader.vue";
|
|
46
47
|
export { default as EUICircleLoader } from "./loader/EUICircleLoader.vue";
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import type { Meta, StoryObj } from "@storybook/vue3";
|
|
2
2
|
import EUIPopover from "./EUIPopover.vue";
|
|
3
|
+
import EUIButton from "../button/EUIButton.vue";
|
|
3
4
|
import { InformationCircleIcon } from "@heroicons/vue/24/outline";
|
|
4
5
|
import { ref } from "vue";
|
|
6
|
+
import ChevronBigDown from "../../assets/svg/ChevronBigDown.vue";
|
|
5
7
|
|
|
6
8
|
const meta: Meta<typeof EUIPopover> = {
|
|
7
9
|
title: "Example/Popover",
|
|
@@ -14,7 +16,7 @@ const meta: Meta<typeof EUIPopover> = {
|
|
|
14
16
|
},
|
|
15
17
|
trigger: {
|
|
16
18
|
control: { type: "select" },
|
|
17
|
-
options: ["click", "hover"],
|
|
19
|
+
options: ["click", "hover", "manual"],
|
|
18
20
|
description:
|
|
19
21
|
"Specifies the trigger for displaying the popper. Default is 'click'.",
|
|
20
22
|
defaultValue: "click",
|
|
@@ -57,7 +59,7 @@ export const Default: Story = {
|
|
|
57
59
|
placement: "bottom",
|
|
58
60
|
},
|
|
59
61
|
render: (args) => ({
|
|
60
|
-
components: { EUIPopover },
|
|
62
|
+
components: { EUIPopover, EUIButton },
|
|
61
63
|
setup() {
|
|
62
64
|
return { args };
|
|
63
65
|
},
|
|
@@ -140,6 +142,7 @@ export const PopoverHover: Story = {
|
|
|
140
142
|
<EUIPopover
|
|
141
143
|
trigger="hover"
|
|
142
144
|
placement="bottom-start"
|
|
145
|
+
:hover-hide-delay="150"
|
|
143
146
|
className="max-w-64 min-w-64"
|
|
144
147
|
title="Popper hover to Shows"
|
|
145
148
|
customButton="border border-gray-600 px-4 py-2 rounded-lg"
|
|
@@ -162,7 +165,7 @@ export const PopoverHover: Story = {
|
|
|
162
165
|
},
|
|
163
166
|
};
|
|
164
167
|
|
|
165
|
-
export const
|
|
168
|
+
export const PopoverManualAccess: Story = {
|
|
166
169
|
args: {
|
|
167
170
|
title: "Popover click to Show",
|
|
168
171
|
className: "max-w-64 min-w-64",
|
|
@@ -171,28 +174,29 @@ export const PopoverEmitAccess: Story = {
|
|
|
171
174
|
placement: "bottom-start",
|
|
172
175
|
},
|
|
173
176
|
render: (args) => ({
|
|
174
|
-
components: { EUIPopover, InformationCircleIcon },
|
|
177
|
+
components: { EUIPopover, InformationCircleIcon, EUIButton },
|
|
175
178
|
setup() {
|
|
176
179
|
const popoverVisible = ref(false);
|
|
177
180
|
|
|
178
|
-
const
|
|
179
|
-
popoverVisible.value =
|
|
181
|
+
const onPopoverToggle = () => {
|
|
182
|
+
popoverVisible.value = !popoverVisible.value;
|
|
180
183
|
};
|
|
181
184
|
|
|
182
185
|
const onPopoverHide = () => {
|
|
183
186
|
popoverVisible.value = false;
|
|
184
187
|
};
|
|
185
188
|
|
|
186
|
-
return { args,
|
|
189
|
+
return { args, popoverVisible, onPopoverToggle, onPopoverHide };
|
|
187
190
|
},
|
|
188
191
|
template: `<div class="min-h-72">
|
|
189
|
-
<EUIPopover v-bind="args" trigger="
|
|
190
|
-
@hidePopover="onPopoverHide">
|
|
192
|
+
<EUIPopover v-bind="args" trigger="manual" v-model:visible="popoverVisible" placement="top" title="Popper Manual Access" @click="onPopoverToggle">
|
|
191
193
|
<template #referenceButton>
|
|
192
194
|
Information <InformationCircleIcon class="text-gray-900 cursor-pointer size-6" />
|
|
193
195
|
</template>
|
|
194
196
|
<div class="relative z-10 px-4 pb-4 pt-0 text-gray-900 bg-white rounded-lg shadow-lg">
|
|
195
197
|
Lorem ipsum dolor sit amet consectetur adipisicing elit. Minima, hic a quidem non delectus, est, ad voluptatum nostrum minus consequatur aut excepturi iste autem distinctio neque porro. Ipsa, quasi enim!
|
|
198
|
+
|
|
199
|
+
<EUIButton type="button" size="sm" color="purple" className="mt-4" @click="onPopoverHide()">Close</EUIButton>
|
|
196
200
|
</div>
|
|
197
201
|
</EUIPopover>
|
|
198
202
|
</div>`,
|
|
@@ -205,28 +209,29 @@ export const PopoverEmitAccess: Story = {
|
|
|
205
209
|
},
|
|
206
210
|
source: {
|
|
207
211
|
code: `<script lang="ts" setup>
|
|
208
|
-
const popoverVisible = ref(false);
|
|
212
|
+
const popoverVisible = ref(false);
|
|
209
213
|
|
|
210
|
-
const
|
|
211
|
-
|
|
212
|
-
};
|
|
214
|
+
const onPopoverToggle = () => {
|
|
215
|
+
popoverVisible.value = !popoverVisible.value;
|
|
216
|
+
};
|
|
213
217
|
|
|
214
|
-
const onPopoverHide = () => {
|
|
215
|
-
|
|
216
|
-
};
|
|
217
|
-
</script>
|
|
218
|
+
const onPopoverHide = () => {
|
|
219
|
+
popoverVisible.value = false;
|
|
220
|
+
};
|
|
221
|
+
</script>
|
|
218
222
|
<template>
|
|
219
223
|
<div>
|
|
220
224
|
Popover is {{ popoverVisible ? "visible" : "hidden" }}
|
|
221
225
|
</div>
|
|
222
226
|
<EUIPopover
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
227
|
+
trigger="manual"
|
|
228
|
+
v-model:visible="popoverVisible"
|
|
229
|
+
placement="top"
|
|
226
230
|
placement="bottom-start"
|
|
227
231
|
className="max-w-64 min-w-64"
|
|
228
|
-
title="Popover
|
|
232
|
+
title="Popover Manual access"
|
|
229
233
|
customButton="border border-gray-600 px-4 py-2 rounded-lg"
|
|
234
|
+
@click="onPopoverToggle"
|
|
230
235
|
>
|
|
231
236
|
<template #referenceButton>
|
|
232
237
|
<InformationCircleIcon class="text-gray-900 cursor-pointer size-6" />
|
|
@@ -238,6 +243,7 @@ const onPopoverHide = () => {
|
|
|
238
243
|
Lorem ipsum dolor sit amet consectetur adipisicing elit. Minima, hic a
|
|
239
244
|
quidem non delectus, est, ad voluptatum nostrum minus consequatur aut
|
|
240
245
|
excepturi iste autem distinctio neque porro. Ipsa, quasi enim!
|
|
246
|
+
<EUIButton type="button" size="sm" color="purple" className="mt-4" @click="onPopoverHide()">Close</EUIButton>
|
|
241
247
|
</div>
|
|
242
248
|
</EUIPopover>
|
|
243
249
|
</template>`,
|
|
@@ -245,3 +251,56 @@ const onPopoverHide = () => {
|
|
|
245
251
|
},
|
|
246
252
|
},
|
|
247
253
|
};
|
|
254
|
+
|
|
255
|
+
export const PopoverDefaultOpen: Story = {
|
|
256
|
+
args: {
|
|
257
|
+
title: "Popover hover to Shows",
|
|
258
|
+
className: "max-w-64 min-w-64",
|
|
259
|
+
customButton: "border border-gray-600 px-4 py-2 rounded-lg",
|
|
260
|
+
trigger: "hover",
|
|
261
|
+
placement: "bottom-start",
|
|
262
|
+
},
|
|
263
|
+
render: (args) => ({
|
|
264
|
+
components: { EUIPopover, InformationCircleIcon, ChevronBigDown },
|
|
265
|
+
setup() {
|
|
266
|
+
const isInitiallyOpen = ref(true);
|
|
267
|
+
|
|
268
|
+
return { args, isInitiallyOpen };
|
|
269
|
+
},
|
|
270
|
+
template: `<div class="min-h-72">
|
|
271
|
+
<EUIPopover v-bind="args" v-model:visible="isInitiallyOpen" placement="bottom-end"
|
|
272
|
+
:hover-hide-delay="150">
|
|
273
|
+
<template #referenceButton #referenceButton="{ open }">
|
|
274
|
+
Information <ChevronBigDown :class="['text-gray-900 cursor-pointer size-6 transition duration-300 ease-in-out transform', open ? '-rotate-90' : 'rotate-0']" />
|
|
275
|
+
</template>
|
|
276
|
+
<div class="relative z-10 px-4 pb-4 pt-0 text-gray-900 bg-white rounded-lg shadow-lg">
|
|
277
|
+
Lorem ipsum dolor sit amet consectetur adipisicing elit. Minima, hic a quidem non delectus, est, ad voluptatum nostrum minus consequatur aut excepturi iste autem distinctio neque porro. Ipsa, quasi enim!
|
|
278
|
+
</div>
|
|
279
|
+
</EUIPopover>
|
|
280
|
+
</div>`,
|
|
281
|
+
}),
|
|
282
|
+
parameters: {
|
|
283
|
+
docs: {
|
|
284
|
+
description: {
|
|
285
|
+
story:
|
|
286
|
+
"The `PopoverHover` story showcases the `EUIPopover` component triggered on hover.",
|
|
287
|
+
},
|
|
288
|
+
source: {
|
|
289
|
+
code: `<script lang="ts" setup>
|
|
290
|
+
const isInitiallyOpen = ref(true);
|
|
291
|
+
</script>
|
|
292
|
+
<template>
|
|
293
|
+
<EUIPopover v-bind="args" v-model:visible="isInitiallyOpen" placement="bottom-end"
|
|
294
|
+
:hover-hide-delay="150">
|
|
295
|
+
<template #referenceButton #referenceButton="{ open }">
|
|
296
|
+
Information <ChevronBigDown :class="['text-gray-900 cursor-pointer size-6 transition duration-300 ease-in-out transform', open ? '-rotate-90' : 'rotate-0']" />
|
|
297
|
+
</template>
|
|
298
|
+
<div class="relative z-10 px-4 pb-4 pt-0 text-gray-900 bg-white rounded-lg shadow-lg">
|
|
299
|
+
Lorem ipsum dolor sit amet consectetur adipisicing elit. Minima, hic a quidem non delectus, est, ad voluptatum nostrum minus consequatur aut excepturi iste autem distinctio neque porro. Ipsa, quasi enim!
|
|
300
|
+
</div>
|
|
301
|
+
</EUIPopover>
|
|
302
|
+
</template>`,
|
|
303
|
+
},
|
|
304
|
+
},
|
|
305
|
+
},
|
|
306
|
+
};
|