mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-01-24 09:16:09 +01:00
🎨 Brand new marketplace UI https://github.com/siyuan-note/siyuan/issues/8181
This commit is contained in:
parent
f5f5a1d428
commit
9e1dbd9b96
8 changed files with 129 additions and 159 deletions
|
|
@ -39,7 +39,7 @@ func BazaarPlugins() (plugins []*bazaar.Plugin) {
|
|||
if plugin.Installed {
|
||||
if plugin.Installed {
|
||||
if pluginConf, err := bazaar.PluginJSON(plugin.Name); nil == err && nil != plugin {
|
||||
if plugin.Version != pluginConf["version"].(string) {
|
||||
if plugin.Version != pluginConf.Version {
|
||||
plugin.Outdated = true
|
||||
}
|
||||
}
|
||||
|
|
@ -79,7 +79,7 @@ func BazaarWidgets() (widgets []*bazaar.Widget) {
|
|||
if widget.Installed {
|
||||
if widget.Installed {
|
||||
if widgetConf, err := bazaar.WidgetJSON(widget.Name); nil == err && nil != widget {
|
||||
if widget.Version != widgetConf["version"].(string) {
|
||||
if widget.Version != widgetConf.Version {
|
||||
widget.Outdated = true
|
||||
}
|
||||
}
|
||||
|
|
@ -119,7 +119,7 @@ func BazaarIcons() (icons []*bazaar.Icon) {
|
|||
if installed == icon.Name {
|
||||
icon.Installed = true
|
||||
if themeConf, err := bazaar.IconJSON(icon.Name); nil == err {
|
||||
if icon.Version != themeConf["version"].(string) {
|
||||
if icon.Version != themeConf.Version {
|
||||
icon.Outdated = true
|
||||
}
|
||||
}
|
||||
|
|
@ -170,7 +170,7 @@ func BazaarThemes() (ret []*bazaar.Theme) {
|
|||
if installed == theme.Name {
|
||||
theme.Installed = true
|
||||
if themeConf, err := bazaar.ThemeJSON(theme.Name); nil == err {
|
||||
theme.Outdated = theme.Version != themeConf["version"].(string)
|
||||
theme.Outdated = theme.Version != themeConf.Version
|
||||
}
|
||||
theme.Current = theme.Name == Conf.Appearance.ThemeDark || theme.Name == Conf.Appearance.ThemeLight
|
||||
}
|
||||
|
|
@ -231,7 +231,7 @@ func BazaarTemplates() (templates []*bazaar.Template) {
|
|||
template.Installed = gulu.File.IsExist(filepath.Join(util.DataDir, "templates", template.Name))
|
||||
if template.Installed {
|
||||
if themeConf, err := bazaar.TemplateJSON(template.Name); nil == err && nil != themeConf {
|
||||
if template.Version != themeConf["version"].(string) {
|
||||
if template.Version != themeConf.Version {
|
||||
template.Outdated = true
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue