@cloudron/pankow 3.5.11 → 3.5.13
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/components/Dialog.vue +5 -0
- package/components/TableView.vue +12 -2
- package/package.json +1 -1
- package/style.css +1 -4
- package/tooltip.js +1 -1
package/components/Dialog.vue
CHANGED
|
@@ -43,6 +43,10 @@ const props = defineProps({
|
|
|
43
43
|
type: Boolean,
|
|
44
44
|
default: false
|
|
45
45
|
},
|
|
46
|
+
dismissable: {
|
|
47
|
+
type: Boolean,
|
|
48
|
+
default: true
|
|
49
|
+
},
|
|
46
50
|
confirmLabel: String,
|
|
47
51
|
rejectLabel: String,
|
|
48
52
|
alternateLabel: String,
|
|
@@ -81,6 +85,7 @@ function onConfirm() {
|
|
|
81
85
|
}
|
|
82
86
|
|
|
83
87
|
function onDismiss() {
|
|
88
|
+
if (!props.dismissable) return;
|
|
84
89
|
onReject();
|
|
85
90
|
}
|
|
86
91
|
|
package/components/TableView.vue
CHANGED
|
@@ -22,6 +22,10 @@ const props = defineProps({
|
|
|
22
22
|
validator(value, props) {
|
|
23
23
|
return [ 'asc', 'desc' ].includes(value);
|
|
24
24
|
}
|
|
25
|
+
},
|
|
26
|
+
fixedLayout: {
|
|
27
|
+
type: Boolean,
|
|
28
|
+
default: false,
|
|
25
29
|
}
|
|
26
30
|
});
|
|
27
31
|
|
|
@@ -92,13 +96,13 @@ onMounted(() => {
|
|
|
92
96
|
<template>
|
|
93
97
|
<div class="pankow-table-scroll-wrapper">
|
|
94
98
|
<div class="pankow-table-wrapper">
|
|
95
|
-
<table class="pankow-table">
|
|
99
|
+
<table class="pankow-table" :class="{ 'pankow-table-layout-fixed': fixedLayout }">
|
|
96
100
|
<thead class="pankow-table-header" v-if="sortedItems.length !== 0">
|
|
97
101
|
<tr>
|
|
98
102
|
<th v-for="column in Object.keys(columns)"
|
|
99
103
|
class="pankow-table-header-column"
|
|
100
104
|
:class="{ 'pankow-table-header-column-sortable': columns[column].sort, 'pankow-table-cell-hide-mobile': columns[column].hideMobile }"
|
|
101
|
-
:style="{ 'text-align': columns[column].align || null }"
|
|
105
|
+
:style="{ 'text-align': columns[column].align || null, width: typeof columns[column].width === 'string' ? columns[column].width : 'auto' }"
|
|
102
106
|
@click="toggleSort(column)"
|
|
103
107
|
>
|
|
104
108
|
<Icon v-if="columns[column].icon" :icon="columns[column].icon" />
|
|
@@ -154,6 +158,10 @@ onMounted(() => {
|
|
|
154
158
|
border-spacing: 0px;
|
|
155
159
|
}
|
|
156
160
|
|
|
161
|
+
.pankow-table-layout-fixed {
|
|
162
|
+
table-layout: fixed;
|
|
163
|
+
}
|
|
164
|
+
|
|
157
165
|
.pankow-table-header {
|
|
158
166
|
top: 0;
|
|
159
167
|
position: sticky;
|
|
@@ -186,6 +194,7 @@ onMounted(() => {
|
|
|
186
194
|
.pankow-table-cell {
|
|
187
195
|
padding: 5px;
|
|
188
196
|
height: 100%;
|
|
197
|
+
overflow: hidden;
|
|
189
198
|
}
|
|
190
199
|
|
|
191
200
|
.pankow-table-row-with-hover:hover {
|
|
@@ -199,6 +208,7 @@ onMounted(() => {
|
|
|
199
208
|
|
|
200
209
|
.pankow-table-cell-nowrap {
|
|
201
210
|
white-space: nowrap;
|
|
211
|
+
text-overflow: ellipsis;
|
|
202
212
|
}
|
|
203
213
|
|
|
204
214
|
@media (max-width: 576px) {
|
package/package.json
CHANGED
package/style.css
CHANGED
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
|
|
24
24
|
--pankow-color-light-dark: #ced4da;
|
|
25
25
|
|
|
26
|
-
--pankow-tooltip-background-color:
|
|
26
|
+
--pankow-tooltip-background-color: #333;
|
|
27
27
|
--pankow-tooltip-text-color: white;
|
|
28
28
|
|
|
29
29
|
--pankow-color-primary: #1a76bf;
|
|
@@ -100,9 +100,6 @@ input {
|
|
|
100
100
|
|
|
101
101
|
--pankow-dialog-background-color: #32383e;
|
|
102
102
|
--pankow-dialog-backdrop-color: rgba(0,0,0,.7);
|
|
103
|
-
|
|
104
|
-
--pankow-tooltip-background-color: rgba(255,255,255,0.5);
|
|
105
|
-
--pankow-tooltip-text-color: black;
|
|
106
103
|
}
|
|
107
104
|
}
|
|
108
105
|
|
package/tooltip.js
CHANGED
|
@@ -55,7 +55,7 @@ function update(target, value, modifiers, tooltip) {
|
|
|
55
55
|
tooltip.innerText = value;
|
|
56
56
|
|
|
57
57
|
// BOTTOM is default
|
|
58
|
-
const pos = modifiers.top ? TOP : (modifiers.left ? LEFT : (modifiers.
|
|
58
|
+
const pos = modifiers.top ? TOP : (modifiers.left ? LEFT : (modifiers.right ? RIGHT : BOTTOM));
|
|
59
59
|
|
|
60
60
|
const targetRect = target.getBoundingClientRect();
|
|
61
61
|
const tooltipRect = tooltip.getBoundingClientRect();
|