@dataloop-ai/components 0.19.4 → 0.19.6
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
|
@@ -111,8 +111,6 @@ export default defineComponent({
|
|
|
111
111
|
title: { type: String, default: '' },
|
|
112
112
|
subtitle: { type: String, default: '' },
|
|
113
113
|
withCloseButton: Boolean,
|
|
114
|
-
height: { type: String, default: 'auto' },
|
|
115
|
-
width: { type: String, default: 'auto' },
|
|
116
114
|
draggable: Boolean,
|
|
117
115
|
isEmpty: Boolean,
|
|
118
116
|
emptyStateProps: {
|
|
@@ -151,8 +149,9 @@ export default defineComponent({
|
|
|
151
149
|
type: String as PropType<Element | string>,
|
|
152
150
|
default: null
|
|
153
151
|
},
|
|
154
|
-
|
|
155
152
|
touchPosition: Boolean,
|
|
153
|
+
height: { type: String, default: 'auto' },
|
|
154
|
+
width: { type: String, default: 'auto' },
|
|
156
155
|
maxHeight: { type: String, default: 'auto' },
|
|
157
156
|
maxWidth: { type: String, default: 'auto' },
|
|
158
157
|
menuClass: {
|
|
@@ -169,10 +168,11 @@ export default defineComponent({
|
|
|
169
168
|
},
|
|
170
169
|
/**
|
|
171
170
|
* the % of the parent element that triggers the tooltips visibility
|
|
171
|
+
* @default 0 - no hide occurs when trigger % is 0
|
|
172
172
|
*/
|
|
173
173
|
triggerPercentage: {
|
|
174
174
|
type: Number,
|
|
175
|
-
default:
|
|
175
|
+
default: 0
|
|
176
176
|
}
|
|
177
177
|
},
|
|
178
178
|
emits: [...useModelToggleEmits, 'click', 'escapekey', 'close-button-click'],
|
|
@@ -229,8 +229,6 @@ export default defineComponent({
|
|
|
229
229
|
title,
|
|
230
230
|
subtitle,
|
|
231
231
|
withCloseButton,
|
|
232
|
-
height,
|
|
233
|
-
width,
|
|
234
232
|
isEmpty,
|
|
235
233
|
emptyStateProps,
|
|
236
234
|
modelValue,
|
|
@@ -133,7 +133,14 @@ export default defineComponent({
|
|
|
133
133
|
},
|
|
134
134
|
|
|
135
135
|
touchPosition: Boolean,
|
|
136
|
-
|
|
136
|
+
width: {
|
|
137
|
+
type: String,
|
|
138
|
+
default: 'auto'
|
|
139
|
+
},
|
|
140
|
+
height: {
|
|
141
|
+
type: String,
|
|
142
|
+
default: 'auto'
|
|
143
|
+
},
|
|
137
144
|
maxHeight: {
|
|
138
145
|
type: String,
|
|
139
146
|
default: null
|
|
@@ -421,12 +428,12 @@ export default defineComponent({
|
|
|
421
428
|
return
|
|
422
429
|
}
|
|
423
430
|
|
|
424
|
-
const isAnchorElVisible =
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
431
|
+
const isAnchorElVisible =
|
|
432
|
+
props.triggerPercentage === 0
|
|
433
|
+
? true
|
|
434
|
+
: await CheckAnchorElVisibility(anchorEl.value, {
|
|
435
|
+
triggerPercentage: props.triggerPercentage
|
|
436
|
+
})
|
|
430
437
|
|
|
431
438
|
if (!isAnchorElVisible) {
|
|
432
439
|
hide()
|
|
@@ -480,7 +487,9 @@ export default defineComponent({
|
|
|
480
487
|
attrs.style,
|
|
481
488
|
transitionStyle.value,
|
|
482
489
|
{
|
|
483
|
-
'--menu-z-index': props.zIndex ?? 'var(--dl-z-index-menu)'
|
|
490
|
+
'--menu-z-index': props.zIndex ?? 'var(--dl-z-index-menu)',
|
|
491
|
+
'--menu-height': props.height,
|
|
492
|
+
'--menu-width': props.width
|
|
484
493
|
}
|
|
485
494
|
] as any,
|
|
486
495
|
selectedItem,
|
|
@@ -495,6 +504,8 @@ export default defineComponent({
|
|
|
495
504
|
position: fixed !important;
|
|
496
505
|
display: inline-block;
|
|
497
506
|
max-width: 95vw;
|
|
507
|
+
height: var(--menu-height);
|
|
508
|
+
width: var(--menu-width);
|
|
498
509
|
border: 1px solid var(--dl-color-separator);
|
|
499
510
|
|
|
500
511
|
box-shadow: var(--dl-menu-shadow);
|
|
@@ -224,6 +224,39 @@
|
|
|
224
224
|
</template>
|
|
225
225
|
</dl-popup>
|
|
226
226
|
</dl-button>
|
|
227
|
+
<dl-button label="Open Popup with height and width">
|
|
228
|
+
<dl-popup
|
|
229
|
+
title="Edit Item Description"
|
|
230
|
+
additional-info="Some additional information"
|
|
231
|
+
subtitle="Some text for better explanation."
|
|
232
|
+
with-close-button
|
|
233
|
+
:style="{ '--dl-popup-padding': '0px' }"
|
|
234
|
+
height="50px"
|
|
235
|
+
width="500px"
|
|
236
|
+
>
|
|
237
|
+
<dl-text-area
|
|
238
|
+
v-model="text"
|
|
239
|
+
:max-length="100"
|
|
240
|
+
show-counter
|
|
241
|
+
placeholder="Type your text"
|
|
242
|
+
width="203px"
|
|
243
|
+
/>
|
|
244
|
+
<template #close-button>
|
|
245
|
+
<dl-button
|
|
246
|
+
flat
|
|
247
|
+
style="padding-bottom: 0; padding-top: 0"
|
|
248
|
+
label="clear"
|
|
249
|
+
size="m"
|
|
250
|
+
@click="handleClear"
|
|
251
|
+
/>
|
|
252
|
+
</template>
|
|
253
|
+
<template #footer>
|
|
254
|
+
<dl-button fluid>
|
|
255
|
+
Save
|
|
256
|
+
</dl-button>
|
|
257
|
+
</template>
|
|
258
|
+
</dl-popup>
|
|
259
|
+
</dl-button>
|
|
227
260
|
</div>
|
|
228
261
|
</template>
|
|
229
262
|
<script lang="ts">
|