ebt-vue3 2.11.16 → 2.12.2
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
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ebt-vue3",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.12.2",
|
|
4
4
|
"description": "Vue3 Library for SuttaCentral Voice EBT-Sites",
|
|
5
5
|
"author": "Karl Lew",
|
|
6
6
|
"scripts": {
|
|
@@ -30,14 +30,14 @@
|
|
|
30
30
|
"module": "index.mjs",
|
|
31
31
|
"dependencies": {
|
|
32
32
|
"@mdi/font": "7.0.96",
|
|
33
|
-
"@sc-voice/ms-dpd": "^2.
|
|
33
|
+
"@sc-voice/ms-dpd": "^2.46.0",
|
|
34
34
|
"compression": "^1.7.4",
|
|
35
35
|
"idb-keyval": "^6.2.0",
|
|
36
36
|
"log-instance": "^1.6.0",
|
|
37
37
|
"merkle-json": "^2.7.0",
|
|
38
38
|
"pinia": "^2.0.16",
|
|
39
39
|
"roboto-fontface": "*",
|
|
40
|
-
"scv-esm": "^1.111.
|
|
40
|
+
"scv-esm": "^1.111.17",
|
|
41
41
|
"serve-favicon": "^2.5.0",
|
|
42
42
|
"uuid": "^9.0.0",
|
|
43
43
|
"vite-plugin-vuetify": "^2.0.3",
|
|
@@ -79,6 +79,7 @@
|
|
|
79
79
|
import { Examples, SuttaRef } from "scv-esm";
|
|
80
80
|
import { getCurrentInstance, nextTick, ref } from "vue";
|
|
81
81
|
import { default as IdbSutta } from '../idb-sutta.mjs';
|
|
82
|
+
import { Dictionary } from "@sc-voice/ms-dpd/main.mjs";
|
|
82
83
|
import { ACTION, DBG, } from '../defines.mjs';
|
|
83
84
|
import Utils from "../utils.mjs";
|
|
84
85
|
import * as Idb from "idb-keyval";
|
|
@@ -361,11 +362,23 @@
|
|
|
361
362
|
let { volatile, cardScid, paliWord, segment } = this;
|
|
362
363
|
let { dictionary, docLang } = volatile;
|
|
363
364
|
let entry = dictionary.entryOf(paliWord);
|
|
365
|
+
if (!entry) {
|
|
366
|
+
let resLink = Dictionary.dpdLink(paliWord);
|
|
367
|
+
let { url, ebtWord, dpdWord } = resLink;
|
|
368
|
+
return [
|
|
369
|
+
`<a href="${url}" target="_blank">`,
|
|
370
|
+
dpdWord,
|
|
371
|
+
'(DPD)',
|
|
372
|
+
'</a>',
|
|
373
|
+
].join(' ');
|
|
374
|
+
}
|
|
375
|
+
|
|
364
376
|
dbg && console.log(msg, `[1]${paliWord}`, docLang, entry);
|
|
365
377
|
let { definition=['?|?||'] } = entry || {};
|
|
366
|
-
let paliLink
|
|
367
|
-
|
|
368
|
-
|
|
378
|
+
let paliLink;
|
|
379
|
+
paliLink = entry.definition
|
|
380
|
+
? `<a href="#/pali/${entry.word}">${entry.word}</a>`
|
|
381
|
+
: `<b>${entry.word}</b>`;
|
|
369
382
|
|
|
370
383
|
let { $t } = ctx;
|
|
371
384
|
let dpdLit = $t('ebt.dpdLit');
|
package/src/stores/volatile.mjs
CHANGED
|
@@ -704,6 +704,10 @@ export const useVolatileStore = defineStore('volatile', {
|
|
|
704
704
|
|
|
705
705
|
return segment;
|
|
706
706
|
},
|
|
707
|
+
dpdLink(paliWord) {
|
|
708
|
+
let { url } = Dictionary.dpdLink(paliWord);
|
|
709
|
+
return url;
|
|
710
|
+
},
|
|
707
711
|
dpdCartoucheHtml(def, iList, opts={}) {
|
|
708
712
|
let { showLemma=false } = opts;
|
|
709
713
|
let { lemma_1, word } = def;
|