1
0
mirror of https://github.com/garraflavatra/rolens.git synced 2024-12-01 13:20:54 +00:00

Added some s to dropdown items

This commit is contained in:
Romein van Buren 2023-01-17 20:53:01 +01:00
parent 6469cdb630
commit 9262c92591
Signed by: romein
GPG Key ID: 0EFF8478ADDF6C49

View File

@ -80,18 +80,18 @@
children: Object.keys(connection.databases[dbKey].collections).map(collKey => ({
id: collKey,
menu: [
{ label: `Drop ${collKey}`, fn: () => dropCollection(dbKey, collKey) },
{ label: `Drop ${dbKey}`, fn: () => dropDatabase(dbKey) },
{ label: `Drop ${collKey}`, fn: () => dropCollection(dbKey, collKey) },
{ label: `Drop ${dbKey}`, fn: () => dropDatabase(dbKey) },
{ separator: true },
{ label: 'New database', fn: () => dispatch('newDatabase') },
{ label: 'New collection', fn: () => dispatch('newCollection') },
{ label: 'New database', fn: () => dispatch('newDatabase') },
{ label: 'New collection', fn: () => dispatch('newCollection') },
],
})).sort((a, b) => a.id.localeCompare(b)) || [],
menu: [
{ label: `Drop ${dbKey}`, fn: () => dropDatabase(dbKey) },
{ label: `Drop ${dbKey}`, fn: () => dropDatabase(dbKey) },
{ separator: true },
{ label: 'New database', fn: () => dispatch('newDatabase') },
{ label: 'New collection', fn: () => dispatch('newCollection') },
{ label: 'New database', fn: () => dispatch('newDatabase') },
{ label: 'New collection', fn: () => dispatch('newCollection') },
],
}))}
actions={[
@ -99,8 +99,8 @@
{ icon: '+', fn: evt => {
if (activeDbKey) {
contextMenu.show(evt, [
{ label: 'New database', fn: () => dispatch('newDatabase') },
{ label: 'New collection', fn: () => dispatch('newCollection') },
{ label: 'New database', fn: () => dispatch('newDatabase') },
{ label: 'New collection', fn: () => dispatch('newCollection') },
]);
}
else {
@ -110,8 +110,8 @@
{ icon: '-', fn: evt => {
if (activeCollKey) {
contextMenu.show(evt, [
{ label: 'Drop database', fn: () => dropDatabase(activeDbKey) },
{ label: 'Drop collection', fn: () => dropCollection(activeDbKey, activeCollKey) },
{ label: 'Drop database', fn: () => dropDatabase(activeDbKey) },
{ label: 'Drop collection', fn: () => dropCollection(activeDbKey, activeCollKey) },
]);
}
else {