@finema/finework-layer 2.0.67 → 2.0.68
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/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [2.0.68](https://gitlab.finema.co/finema/internal/finework/compare/2.0.67...2.0.68) (2026-09-21)
|
|
4
|
+
|
|
5
|
+
### Features
|
|
6
|
+
|
|
7
|
+
* add collapsible section to show/hide manuals from other apps ([8df4985](https://gitlab.finema.co/finema/internal/finework/commit/8df498555ec378057030d459759934523f2e3523))
|
|
8
|
+
|
|
3
9
|
## [2.0.67](https://gitlab.finema.co/finema/internal/finework/compare/2.0.66...2.0.67) (2026-09-20)
|
|
4
10
|
|
|
5
11
|
### Bug Fixes
|
|
@@ -109,7 +109,7 @@
|
|
|
109
109
|
<div class="flex-1 overflow-y-auto p-3">
|
|
110
110
|
<Loader :loading="loading && !manuals.length">
|
|
111
111
|
<div
|
|
112
|
-
v-if="!
|
|
112
|
+
v-if="!visibleGroups.length"
|
|
113
113
|
class="flex flex-col items-center justify-center gap-2 px-8 py-16 text-center"
|
|
114
114
|
>
|
|
115
115
|
<div class="mb-2 flex size-16 items-center justify-center rounded-full bg-gray-100 text-gray-400">
|
|
@@ -137,7 +137,7 @@
|
|
|
137
137
|
</div>
|
|
138
138
|
|
|
139
139
|
<div
|
|
140
|
-
v-for="group in
|
|
140
|
+
v-for="group in visibleGroups"
|
|
141
141
|
:key="group.app"
|
|
142
142
|
class="mb-3 last:mb-0"
|
|
143
143
|
>
|
|
@@ -210,6 +210,19 @@
|
|
|
210
210
|
/>
|
|
211
211
|
</button>
|
|
212
212
|
</div>
|
|
213
|
+
|
|
214
|
+
<button
|
|
215
|
+
v-if="otherGroups.length"
|
|
216
|
+
class="text-primary-600 flex w-full cursor-pointer items-center justify-center gap-1.5 rounded-xl p-2.5 text-xs font-semibold hover:bg-gray-50"
|
|
217
|
+
type="button"
|
|
218
|
+
@click="showOtherApps = !showOtherApps"
|
|
219
|
+
>
|
|
220
|
+
<Icon
|
|
221
|
+
:name="showOtherApps ? 'ph:caret-up' : 'ph:caret-down'"
|
|
222
|
+
class="size-3.5"
|
|
223
|
+
/>
|
|
224
|
+
{{ showOtherApps ? 'ซ่อนคู่มือแอปอื่น' : `ดูคู่มือแอปอื่น (${otherGroups.length})` }}
|
|
225
|
+
</button>
|
|
213
226
|
</Loader>
|
|
214
227
|
</div>
|
|
215
228
|
|
|
@@ -338,14 +351,12 @@ const mode = ref<Mode>('list')
|
|
|
338
351
|
const selectedId = ref<string | null>(null)
|
|
339
352
|
const editing = ref<IManual | null>(null)
|
|
340
353
|
const confirmDelete = ref<IManual | null>(null)
|
|
354
|
+
const showOtherApps = ref(false)
|
|
341
355
|
|
|
342
356
|
const current = computed<IManual | null>(
|
|
343
357
|
() => props.manuals.find((m) => m.id === selectedId.value) ?? null,
|
|
344
358
|
)
|
|
345
359
|
|
|
346
|
-
// The API sets X-Frame-Options/CSP frame-ancestors that block embedding the
|
|
347
|
-
// PDF URL directly in an <iframe> across subdomains. Fetching the bytes and
|
|
348
|
-
// rendering via a blob: URL sidesteps that, since it isn't a framed request.
|
|
349
360
|
const viewerBlobUrl = ref<string | null>(null)
|
|
350
361
|
const viewerError = ref(false)
|
|
351
362
|
|
|
@@ -465,6 +476,16 @@ const groups = computed(() => {
|
|
|
465
476
|
})
|
|
466
477
|
})
|
|
467
478
|
|
|
479
|
+
const otherGroups = computed(() =>
|
|
480
|
+
props.currentModule ? groups.value.filter((g) => g.app !== props.currentModule) : [],
|
|
481
|
+
)
|
|
482
|
+
|
|
483
|
+
const visibleGroups = computed(() => {
|
|
484
|
+
if (!props.currentModule || showOtherApps.value) return groups.value
|
|
485
|
+
|
|
486
|
+
return groups.value.filter((g) => g.app === props.currentModule)
|
|
487
|
+
})
|
|
488
|
+
|
|
468
489
|
const headerTitle = computed(() => {
|
|
469
490
|
if (mode.value === 'view' && current.value) return current.value.name
|
|
470
491
|
if (mode.value === 'form') return editing.value ? 'แก้ไขคู่มือ' : 'เพิ่มคู่มือ'
|
|
@@ -540,5 +561,6 @@ useWatchTrue(() => props.isOpen, () => {
|
|
|
540
561
|
mode.value = 'list'
|
|
541
562
|
selectedId.value = null
|
|
542
563
|
editing.value = null
|
|
564
|
+
showOtherApps.value = false
|
|
543
565
|
})
|
|
544
566
|
</script>
|