@cloudron/pankow 3.2.23 → 3.3.1
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 +4 -0
- package/components/FormGroup.vue +5 -0
- package/components/SingleSelect.vue +5 -1
- package/package.json +1 -1
- package/utils.js +5 -2
package/components/Dialog.vue
CHANGED
package/components/FormGroup.vue
CHANGED
|
@@ -55,6 +55,7 @@ const menuModel = computed(() => {
|
|
|
55
55
|
return {
|
|
56
56
|
label: item[props.optionLabel],
|
|
57
57
|
disabled: item.disabled,
|
|
58
|
+
icon: item.icon,
|
|
58
59
|
action: () => {
|
|
59
60
|
if (selected.value === item) return;
|
|
60
61
|
|
|
@@ -160,7 +161,10 @@ onMounted(() => {
|
|
|
160
161
|
<template>
|
|
161
162
|
<div class="pankow-singleselect" :class="{ 'pankow-singleselect-disabled': disabled }" ref="elem" tabindex="0" @click="onClick" @keydown.enter="onOpen" @keydown.down.stop.prevent="onSelectNext" @keydown.up.stop.prevent="onSelectPrev" @keydown.esc.stop="onClose" @keydown.stop="onKeyDown($event)">
|
|
162
163
|
<Menu ref="menu" :model="menuModel" :search-threshold="searchThreshold" :close-on-activation="true" @close="onMenuClosed"/>
|
|
163
|
-
|
|
164
|
+
<span>
|
|
165
|
+
<Icon v-if="selected ? selected.icon : false" :icon="selected.icon" style="margin-right: 6px" />
|
|
166
|
+
{{ selected ? selected[optionLabel] : placeholder }}
|
|
167
|
+
</span>
|
|
164
168
|
<Icon icon="fa-solid fa-chevron-down" class="pankow-button-icon-right-with-text" />
|
|
165
169
|
</div>
|
|
166
170
|
</template>
|
package/package.json
CHANGED
package/utils.js
CHANGED
|
@@ -125,8 +125,11 @@ function prettyLongDate(value) {
|
|
|
125
125
|
if (isNaN(date.getTime())) return 'unknown';
|
|
126
126
|
|
|
127
127
|
const formatter = new Intl.DateTimeFormat(undefined, {
|
|
128
|
-
|
|
129
|
-
|
|
128
|
+
day: 'numeric',
|
|
129
|
+
month: 'short',
|
|
130
|
+
year: 'numeric',
|
|
131
|
+
hour: '2-digit',
|
|
132
|
+
minute: '2-digit',
|
|
130
133
|
});
|
|
131
134
|
|
|
132
135
|
const formattedDate = formatter.format(date);
|