mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-05-07 02:20:26 +08:00
Merge remote-tracking branch 'origin/dev' into dev
This commit is contained in:
commit
1f8e40a30e
@ -63,6 +63,7 @@ func Icons() (icons []*Icon) {
|
|||||||
logging.LogErrorf("get bazaar package [%s] failed: %d", innerU, innerResp.StatusCode)
|
logging.LogErrorf("get bazaar package [%s] failed: %d", innerU, innerResp.StatusCode)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
icon.URL = strings.TrimSuffix(icon.URL, "/")
|
||||||
|
|
||||||
repoURLHash := strings.Split(repoURL, "@")
|
repoURLHash := strings.Split(repoURL, "@")
|
||||||
icon.RepoURL = "https://github.com/" + repoURLHash[0]
|
icon.RepoURL = "https://github.com/" + repoURLHash[0]
|
||||||
@ -125,6 +126,7 @@ func InstalledIcons() (ret []*Icon) {
|
|||||||
icon.Name = iconConf["name"].(string)
|
icon.Name = iconConf["name"].(string)
|
||||||
icon.Author = iconConf["author"].(string)
|
icon.Author = iconConf["author"].(string)
|
||||||
icon.URL = iconConf["url"].(string)
|
icon.URL = iconConf["url"].(string)
|
||||||
|
icon.URL = strings.TrimSuffix(icon.URL, "/")
|
||||||
icon.Version = iconConf["version"].(string)
|
icon.Version = iconConf["version"].(string)
|
||||||
icon.RepoURL = icon.URL
|
icon.RepoURL = icon.URL
|
||||||
icon.PreviewURL = "/appearance/icons/" + dirName + "/preview.png"
|
icon.PreviewURL = "/appearance/icons/" + dirName + "/preview.png"
|
||||||
|
@ -64,6 +64,7 @@ func Templates() (templates []*Template) {
|
|||||||
logging.LogErrorf("get bazaar package [%s] failed: %d", innerU, innerResp.StatusCode)
|
logging.LogErrorf("get bazaar package [%s] failed: %d", innerU, innerResp.StatusCode)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
template.URL = strings.TrimSuffix(template.URL, "/")
|
||||||
|
|
||||||
repoURLHash := strings.Split(repoURL, "@")
|
repoURLHash := strings.Split(repoURL, "@")
|
||||||
template.RepoURL = "https://github.com/" + repoURLHash[0]
|
template.RepoURL = "https://github.com/" + repoURLHash[0]
|
||||||
@ -125,6 +126,7 @@ func InstalledTemplates() (ret []*Template) {
|
|||||||
template.Name = templateConf["name"].(string)
|
template.Name = templateConf["name"].(string)
|
||||||
template.Author = templateConf["author"].(string)
|
template.Author = templateConf["author"].(string)
|
||||||
template.URL = templateConf["url"].(string)
|
template.URL = templateConf["url"].(string)
|
||||||
|
template.URL = strings.TrimSuffix(template.URL, "/")
|
||||||
template.Version = templateConf["version"].(string)
|
template.Version = templateConf["version"].(string)
|
||||||
template.RepoURL = template.URL
|
template.RepoURL = template.URL
|
||||||
template.PreviewURL = "/templates/" + dirName + "/preview.png"
|
template.PreviewURL = "/templates/" + dirName + "/preview.png"
|
||||||
|
@ -65,6 +65,7 @@ func Themes() (ret []*Theme) {
|
|||||||
logging.LogErrorf("get bazaar package [%s] failed: %d", innerU, innerResp.StatusCode)
|
logging.LogErrorf("get bazaar package [%s] failed: %d", innerU, innerResp.StatusCode)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
theme.URL = strings.TrimSuffix(theme.URL, "/")
|
||||||
|
|
||||||
repoURLHash := strings.Split(repoURL, "@")
|
repoURLHash := strings.Split(repoURL, "@")
|
||||||
theme.RepoURL = "https://github.com/" + repoURLHash[0]
|
theme.RepoURL = "https://github.com/" + repoURLHash[0]
|
||||||
@ -127,6 +128,7 @@ func InstalledThemes() (ret []*Theme) {
|
|||||||
theme.Name = themeConf["name"].(string)
|
theme.Name = themeConf["name"].(string)
|
||||||
theme.Author = themeConf["author"].(string)
|
theme.Author = themeConf["author"].(string)
|
||||||
theme.URL = themeConf["url"].(string)
|
theme.URL = themeConf["url"].(string)
|
||||||
|
theme.URL = strings.TrimSuffix(theme.URL, "/")
|
||||||
theme.Version = themeConf["version"].(string)
|
theme.Version = themeConf["version"].(string)
|
||||||
for _, mode := range themeConf["modes"].([]interface{}) {
|
for _, mode := range themeConf["modes"].([]interface{}) {
|
||||||
theme.Modes = append(theme.Modes, mode.(string))
|
theme.Modes = append(theme.Modes, mode.(string))
|
||||||
|
@ -64,6 +64,7 @@ func Widgets() (widgets []*Widget) {
|
|||||||
logging.LogErrorf("get bazaar package [%s] failed: %d", innerU, innerResp.StatusCode)
|
logging.LogErrorf("get bazaar package [%s] failed: %d", innerU, innerResp.StatusCode)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
widget.URL = strings.TrimSuffix(widget.URL, "/")
|
||||||
|
|
||||||
repoURLHash := strings.Split(repoURL, "@")
|
repoURLHash := strings.Split(repoURL, "@")
|
||||||
widget.RepoURL = "https://github.com/" + repoURLHash[0]
|
widget.RepoURL = "https://github.com/" + repoURLHash[0]
|
||||||
@ -123,6 +124,7 @@ func InstalledWidgets() (ret []*Widget) {
|
|||||||
widget.Name = widgetConf["name"].(string)
|
widget.Name = widgetConf["name"].(string)
|
||||||
widget.Author = widgetConf["author"].(string)
|
widget.Author = widgetConf["author"].(string)
|
||||||
widget.URL = widgetConf["url"].(string)
|
widget.URL = widgetConf["url"].(string)
|
||||||
|
widget.URL = strings.TrimSuffix(widget.URL, "/")
|
||||||
widget.Version = widgetConf["version"].(string)
|
widget.Version = widgetConf["version"].(string)
|
||||||
widget.RepoURL = widget.URL
|
widget.RepoURL = widget.URL
|
||||||
widget.PreviewURL = "/widgets/" + dirName + "/preview.png"
|
widget.PreviewURL = "/widgets/" + dirName + "/preview.png"
|
||||||
|
Loading…
Reference in New Issue
Block a user