Merge remote-tracking branch 'origin/dev' into dev
This commit is contained in:
commit
44da8fb71d
19 changed files with 1650 additions and 19 deletions
1584
app/appearance/langs/ar_SA.json
Normal file
1584
app/appearance/langs/ar_SA.json
Normal file
File diff suppressed because it is too large
Load diff
|
@ -1,6 +1,7 @@
|
|||
{
|
||||
"second": "Sekunde",
|
||||
"syncInterval": "Synchronisierungsintervall",
|
||||
"syncIntervalTip": "Automatische Datensynchronisierung, nachdem die Daten nicht mehr geändert werden",
|
||||
"removeAV": "Aus der Datenbank entfernen",
|
||||
"empty": "Leer",
|
||||
"newRowInRelation": "Erstellen Sie einen neuen Eintrag in ${x} <b class='ft__on-surface'>${y}</b>",
|
||||
|
@ -913,7 +914,7 @@
|
|||
"insertBefore": "Fügen Sie einen leeren Block vor dem Block ein, an dem sich der Cursor befindet",
|
||||
"insertAfter": "Fügen Sie einen leeren Block nach dem Block ein, an dem sich der Cursor befindet",
|
||||
"list1": "Liste",
|
||||
"insert": "Element einfügen",
|
||||
"element": "Element",
|
||||
"closeTab": "Aktuellen Tab schließen",
|
||||
"keymap": "Tastenbelegung",
|
||||
"clearFontStyle": "Stil löschen",
|
||||
|
|
|
@ -1,4 +1,7 @@
|
|||
{
|
||||
"second": "second",
|
||||
"syncInterval": "sync interval",
|
||||
"syncIntervalTip": "Automatically sync data after it stops changing",
|
||||
"removeAV": "Remove from database",
|
||||
"empty": "Empty",
|
||||
"newRowInRelation": "Create a new entry in ${x} <b class='ft__on-surface'>${y}</b>",
|
||||
|
@ -911,7 +914,7 @@
|
|||
"insertBefore": "Insert an empty block before the block where the cursor is",
|
||||
"insertAfter": "Insert an empty block after the block where the cursor is located",
|
||||
"list1": "List",
|
||||
"insert": "Insert Element",
|
||||
"element": "Element",
|
||||
"closeTab": "Close current Tab",
|
||||
"keymap": "Keymap",
|
||||
"clearFontStyle": "Clear Style",
|
||||
|
|
|
@ -1,8 +1,7 @@
|
|||
{
|
||||
"second": "second",
|
||||
"syncInterval": "Sync interval",
|
||||
"second": "segundo",
|
||||
"syncInterval": "intervalo de sincronización",
|
||||
"syncIntervalTip": "Sincronización automática de datos después de que los datos dejen de cambiar",
|
||||
"removeAV": "Eliminar de la base de datos",
|
||||
"empty": "Vacío",
|
||||
"newRowInRelation": "Crear una nueva entrada en ${x} <b class='ft__on-surface'>${y}</b>",
|
||||
|
@ -915,7 +914,7 @@
|
|||
"insertBefore": "Inserta un bloque vacío antes del bloque donde está el cursor",
|
||||
"insertAfter": "Inserta un bloque vacío después del bloque donde se encuentra el cursor",
|
||||
"list1": "Lista",
|
||||
"insert": "Insertar elemento",
|
||||
"element": "elemento",
|
||||
"closeTab": "Cerrar pestaña actual",
|
||||
"keymap": "Mapa de teclas",
|
||||
"clearFontStyle": "Limpiar estilo",
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
{
|
||||
"second": "seconde",
|
||||
"syncInterval": "intervalle de synchronisation",
|
||||
"syncIntervalTip": "Synchronisation automatique des données après l'arrêt des modifications",
|
||||
"removeAV": "Supprimer de la base de données",
|
||||
"empty": "Vide",
|
||||
"newRowInRelation": "Créer une nouvelle entrée dans ${x} <b class='ft__on-surface'>${y}</b>",
|
||||
|
@ -913,7 +914,7 @@
|
|||
"insertBefore": "Insérer un bloc vide devant le bloc où se trouve le curseur",
|
||||
"insertAfter": "Insérer un bloc vide après le bloc où se trouve le curseur",
|
||||
"list1": "Liste",
|
||||
"insert": "Insérer l'élément",
|
||||
"element": "élément",
|
||||
"closeTab": "Fermer l'onglet actuel",
|
||||
"keymap": "Raccourci",
|
||||
"clearFontStyle": "Effacer Styles",
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
{
|
||||
"second": "שנייה",
|
||||
"syncInterval": "מרווח סנכרון",
|
||||
"syncIntervalTip": "סנכרון נתונים אוטומטי לאחר שהנתונים מפסיקים להשתנות",
|
||||
"removeAV": "הסר ממסד הנתונים",
|
||||
"empty": "ריק",
|
||||
"newRowInRelation": "צור ערך חדש ב-${x} <b class='ft__on-surface'>${y}</b>",
|
||||
|
@ -913,7 +914,7 @@
|
|||
"insertBefore": "הכנס בלוק ריק לפני הבלוק שבו נמצא הסמן",
|
||||
"insertAfter": "הכנס בלוק ריק אחרי הבלוק שבו נמצא הסמן",
|
||||
"list1": "רשימה",
|
||||
"insert": "הכנס אלמנט",
|
||||
"element": "אלמנט",
|
||||
"closeTab": "סגור טאב נוכחי",
|
||||
"keymap": "מפת מקשים",
|
||||
"clearFontStyle": "נקה סגנון",
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
{
|
||||
"second": "secondo",
|
||||
"syncInterval": "intervallo di sincronizzazione",
|
||||
"syncIntervalTip": "Sincronizzazione automatica dei dati dopo che non ci sono più variazioni",
|
||||
"removeAV": "Rimuovi dal database",
|
||||
"empty": "Vuoto",
|
||||
"newRowInRelation": "Crea una nuova voce in ${x} <b class='ft__on-surface'>${y}</b>",
|
||||
|
@ -913,7 +914,7 @@
|
|||
"insertBefore": "Inserisci un blocco vuoto prima del blocco corrente",
|
||||
"insertAfter": "Inserisci un blocco vuoto dopo il blocco corrente",
|
||||
"list1": "Lista",
|
||||
"insert": "Inserisci elemento",
|
||||
"element": "elemento",
|
||||
"closeTab": "Chiudi scheda corrente",
|
||||
"keymap": "Mappa dei tasti",
|
||||
"clearFontStyle": "Pulisci stile",
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
{
|
||||
"second": "秒",
|
||||
"syncInterval": "同期間隔",
|
||||
"syncIntervalTip": "データが変動しなくなった後に自動的にデータを同期します",
|
||||
"removeAV": "データベースから削除",
|
||||
"empty": "空白",
|
||||
"newRowInRelation": "${x} に新しい項目を作成 <b class='ft__on-surface'>${y}</b>",
|
||||
|
@ -913,7 +914,7 @@
|
|||
"insertBefore": "前にブロックを挿入",
|
||||
"insertAfter": "後にブロックを挿入",
|
||||
"list1": "リスト",
|
||||
"insert": "要素の挿入",
|
||||
"element": "要素",
|
||||
"closeTab": "現在のタブを閉じる",
|
||||
"keymap": "ショートカット",
|
||||
"clearFontStyle": "スタイルを消去",
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
{
|
||||
"second": "sekunda",
|
||||
"syncInterval": "interwał synchronizacji",
|
||||
"syncIntervalTip": "Automatyczna synchronizacja danych po zaprzestaniu zmian",
|
||||
"removeAV": "Usuń z bazy danych",
|
||||
"empty": "Pusty",
|
||||
"newRowInRelation": "Utwórz nowy wpis w ${x} <b class='ft__on-surface'>${y}</b>",
|
||||
|
@ -913,7 +914,7 @@
|
|||
"insertBefore": "Wstaw pusty blok przed blokiem, w którym znajduje się kursor",
|
||||
"insertAfter": "Wstaw pusty blok po bloku, w którym znajduje się kursor",
|
||||
"list1": "Lista",
|
||||
"insert": "Wstaw element",
|
||||
"element": "element",
|
||||
"closeTab": "Zamknij bieżący zakładkę",
|
||||
"keymap": "Zestaw klawiszy",
|
||||
"clearFontStyle": "Wyczyść styl",
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
{
|
||||
"second": "секунда",
|
||||
"syncInterval": "интервал синхронизации",
|
||||
"syncIntervalTip": "Автоматическая синхронизация данных после прекращения изменений",
|
||||
"removeAV": "Удалить из базы данных",
|
||||
"empty": "Пусто",
|
||||
"newRowInRelation": "Создать новую запись в ${x} <b class='ft__on-surface'>${y}</b>",
|
||||
|
@ -913,7 +914,7 @@
|
|||
"insertBefore": "Вставить пустой блок перед блоком, где находится курсор",
|
||||
"insertAfter": "Вставить пустой блок после блока, где находится курсор",
|
||||
"list1": "Список",
|
||||
"insert": "Вставить элемент",
|
||||
"element": "элемент",
|
||||
"closeTab": "Закрыть текущую вкладку",
|
||||
"keymap": "Карта клавиш",
|
||||
"clearFontStyle": "Очистить стиль",
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
{
|
||||
"second": "秒",
|
||||
"syncInterval": "同步間隔",
|
||||
"syncIntervalTip": "數據不再變動後自動進行數據同步",
|
||||
"removeAV": "從資料庫中移除",
|
||||
"empty": "空白",
|
||||
"newRowInRelation": "在 ${x} 中新建條目 <b class='ft__on-surface'>${y}</b>",
|
||||
|
@ -913,7 +914,7 @@
|
|||
"insertBefore": "游標所在塊前插入空塊",
|
||||
"insertAfter": "游標所在塊後插入空塊",
|
||||
"list1": "列表",
|
||||
"insert": "插入元素",
|
||||
"element": "元素",
|
||||
"closeTab": "關閉當前分頁",
|
||||
"keymap": "快速鍵",
|
||||
"clearFontStyle": "清除樣式",
|
||||
|
|
|
@ -216,6 +216,7 @@
|
|||
<option value="he_IL">עברית</option>
|
||||
<option value="ru_RU">Русский</option>
|
||||
<option value="pl_PL">Polski</option>
|
||||
<option value="ar_SA">العربية</option>
|
||||
</select>
|
||||
</label>
|
||||
<label class="b3-label">
|
||||
|
@ -265,6 +266,7 @@
|
|||
<option value="he_IL">עברית</option>
|
||||
<option value="ru_RU">Русский</option>
|
||||
<option value="pl_PL">Polski</option>
|
||||
<option value="ar_SA">العربية</option>
|
||||
</select>
|
||||
</label>
|
||||
<label class="b3-label">
|
||||
|
|
|
@ -204,6 +204,7 @@ export abstract class Constants {
|
|||
he_IL: "20210808180117-6v0mkxr",
|
||||
ru_RU: "20210808180117-6v0mkxr",
|
||||
pl_PL: "20210808180117-6v0mkxr",
|
||||
ar_SA: "20210808180117-6v0mkxr"
|
||||
};
|
||||
public static readonly QUICK_DECK_ID = "20230218211946-2kw8jgx";
|
||||
|
||||
|
|
3
app/src/types/config.d.ts
vendored
3
app/src/types/config.d.ts
vendored
|
@ -279,7 +279,8 @@ declare namespace Config {
|
|||
| "de_DE"
|
||||
| "he_IL"
|
||||
| "ru_RU"
|
||||
| "pl_PL";
|
||||
| "pl_PL"
|
||||
| "ar_SA";
|
||||
|
||||
/**
|
||||
* SiYuan bazaar related configuration
|
||||
|
|
|
@ -253,9 +253,6 @@ func UninstallBazaarPlugin(pluginName, frontend string) error {
|
|||
}
|
||||
}
|
||||
petals = tmp
|
||||
if 1 > len(petals) {
|
||||
petals = []*Petal{}
|
||||
}
|
||||
savePetals(petals)
|
||||
return nil
|
||||
}
|
||||
|
|
|
@ -648,6 +648,7 @@ func GetDoc(startID, endID, id string, index int, query string, queryTypes map[s
|
|||
}
|
||||
}
|
||||
|
||||
existKeywords := 0 < len(keywords)
|
||||
for _, n := range nodes {
|
||||
var unlinks []*ast.Node
|
||||
ast.Walk(n, func(n *ast.Node, entering bool) ast.WalkStatus {
|
||||
|
@ -679,7 +680,7 @@ func GetDoc(startID, endID, id string, index int, query string, queryTypes map[s
|
|||
}
|
||||
}
|
||||
|
||||
if highlight && 0 < len(keywords) {
|
||||
if highlight && existKeywords {
|
||||
hitBlock := false
|
||||
for p := n.Parent; nil != p; p = p.Parent {
|
||||
if p.ID == id {
|
||||
|
@ -702,6 +703,16 @@ func GetDoc(startID, endID, id string, index int, query string, queryTypes map[s
|
|||
}
|
||||
}
|
||||
|
||||
if existKeywords && id == n.ID {
|
||||
inlines := n.ChildrenByType(ast.NodeTextMark)
|
||||
for _, inline := range inlines {
|
||||
if inline.IsTextMarkType("inline-memo") && util.ContainsSubStr(inline.TextMarkInlineMemoContent, keywords) {
|
||||
// 支持行级备注搜索定位 https://github.com/siyuan-note/siyuan/issues/13465
|
||||
keywords = append(keywords, inline.TextMarkTextContent)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if processVirtualRef(n, &unlinks, virtualBlockRefKeywords, refCount, luteEngine) {
|
||||
return ast.WalkContinue
|
||||
}
|
||||
|
@ -726,6 +737,7 @@ func GetDoc(startID, endID, id string, index int, query string, queryTypes map[s
|
|||
keyword = strings.TrimSuffix(keyword, "#")
|
||||
keywords[i] = keyword
|
||||
}
|
||||
keywords = gulu.Str.RemoveDuplicatedElem(keywords)
|
||||
|
||||
go setRecentDocByTree(tree)
|
||||
return
|
||||
|
|
|
@ -184,6 +184,13 @@ var petalsStoreLock = sync.Mutex{}
|
|||
func savePetals(petals []*Petal) {
|
||||
petalsStoreLock.Lock()
|
||||
defer petalsStoreLock.Unlock()
|
||||
savePetals0(petals)
|
||||
}
|
||||
|
||||
func savePetals0(petals []*Petal) {
|
||||
if 1 > len(petals) {
|
||||
petals = []*Petal{}
|
||||
}
|
||||
|
||||
petalDir := filepath.Join(util.DataDir, "storage", "petal")
|
||||
confPath := filepath.Join(petalDir, "petals.json")
|
||||
|
@ -233,6 +240,21 @@ func getPetals() (ret []*Petal) {
|
|||
logging.LogErrorf("unmarshal petals failed: %s", err)
|
||||
return
|
||||
}
|
||||
|
||||
var tmp []*Petal
|
||||
pluginsDir := filepath.Join(util.DataDir, "plugins")
|
||||
for _, petal := range ret {
|
||||
if petal.Enabled && filelock.IsExist(filepath.Join(pluginsDir, petal.Name)) {
|
||||
tmp = append(tmp, petal)
|
||||
}
|
||||
}
|
||||
if len(tmp) != len(ret) {
|
||||
savePetals0(tmp)
|
||||
ret = tmp
|
||||
}
|
||||
if 1 > len(ret) {
|
||||
ret = []*Petal{}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
@ -1125,7 +1125,9 @@ func FullTextSearchBlock(query string, boxes, paths []string, types map[string]b
|
|||
ret = []*Block{}
|
||||
}
|
||||
|
||||
filterSelfHPath(ret)
|
||||
if 0 == groupBy {
|
||||
filterSelfHPath(ret)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
@ -80,7 +80,7 @@ func Boot() {
|
|||
readOnly := flag.String("readonly", "false", "read-only mode")
|
||||
accessAuthCode := flag.String("accessAuthCode", "", "access auth code")
|
||||
ssl := flag.Bool("ssl", false, "for https and wss")
|
||||
lang := flag.String("lang", "", "zh_CN/zh_CHT/en_US/fr_FR/es_ES/ja_JP/it_IT/de_DE/he_IL/ru_RU/pl_PL")
|
||||
lang := flag.String("lang", "", "zh_CN/zh_CHT/en_US/fr_FR/es_ES/ja_JP/it_IT/de_DE/he_IL/ru_RU/pl_PL/ar_SA")
|
||||
mode := flag.String("mode", "prod", "dev/prod")
|
||||
flag.Parse()
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue