mirror of
https://github.com/noctalia-dev/noctalia-shell.git
synced 2026-05-11 17:08:27 +08:00
PluginsTab: elide urls, move trash icon to the left of toggle
This commit is contained in:
@@ -285,17 +285,20 @@ ColumnLayout {
|
||||
|
||||
ColumnLayout {
|
||||
spacing: Style.marginS
|
||||
Layout.fillWidth: true
|
||||
|
||||
NText {
|
||||
text: modelData.name
|
||||
font.weight: Font.Medium
|
||||
color: Color.mOnSurface
|
||||
Layout.fillWidth: true
|
||||
}
|
||||
|
||||
NText {
|
||||
text: modelData.url
|
||||
font.pointSize: Style.fontSizeS
|
||||
color: Color.mOnSurfaceVariant
|
||||
Layout.fillWidth: true
|
||||
}
|
||||
}
|
||||
|
||||
@@ -303,6 +306,16 @@ ColumnLayout {
|
||||
Layout.fillWidth: true
|
||||
}
|
||||
|
||||
NIconButton {
|
||||
icon: "trash"
|
||||
tooltipText: I18n.tr("settings.plugins.sources.remove.tooltip")
|
||||
visible: index !== 0 // Cannot remove official source
|
||||
baseSize: Style.baseWidgetSize * 0.7
|
||||
onClicked: {
|
||||
PluginRegistry.removePluginSource(modelData.url);
|
||||
}
|
||||
}
|
||||
|
||||
// Enable/Disable a source
|
||||
NToggle {
|
||||
checked: modelData.enabled !== false // Default to true if not set
|
||||
@@ -313,16 +326,6 @@ ColumnLayout {
|
||||
ToastService.showNotice(I18n.tr("settings.plugins.refresh.refreshing"));
|
||||
}
|
||||
}
|
||||
|
||||
NIconButton {
|
||||
icon: "trash"
|
||||
tooltipText: I18n.tr("settings.plugins.sources.remove.tooltip")
|
||||
visible: index !== 0 // Cannot remove official source
|
||||
baseSize: Style.baseWidgetSize * 0.7
|
||||
onClicked: {
|
||||
PluginRegistry.removePluginSource(modelData.url);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user