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:
parent
6469cdb630
commit
9262c92591
@ -80,18 +80,18 @@
|
|||||||
children: Object.keys(connection.databases[dbKey].collections).map(collKey => ({
|
children: Object.keys(connection.databases[dbKey].collections).map(collKey => ({
|
||||||
id: collKey,
|
id: collKey,
|
||||||
menu: [
|
menu: [
|
||||||
{ label: `Drop ${collKey}`, fn: () => dropCollection(dbKey, collKey) },
|
{ label: `Drop ${collKey}…`, fn: () => dropCollection(dbKey, collKey) },
|
||||||
{ label: `Drop ${dbKey}`, fn: () => dropDatabase(dbKey) },
|
{ label: `Drop ${dbKey}…`, fn: () => dropDatabase(dbKey) },
|
||||||
{ separator: true },
|
{ separator: true },
|
||||||
{ label: 'New database', fn: () => dispatch('newDatabase') },
|
{ label: 'New database≥', fn: () => dispatch('newDatabase') },
|
||||||
{ label: 'New collection', fn: () => dispatch('newCollection') },
|
{ label: 'New collection≥', fn: () => dispatch('newCollection') },
|
||||||
],
|
],
|
||||||
})).sort((a, b) => a.id.localeCompare(b)) || [],
|
})).sort((a, b) => a.id.localeCompare(b)) || [],
|
||||||
menu: [
|
menu: [
|
||||||
{ label: `Drop ${dbKey}`, fn: () => dropDatabase(dbKey) },
|
{ label: `Drop ${dbKey}…`, fn: () => dropDatabase(dbKey) },
|
||||||
{ separator: true },
|
{ separator: true },
|
||||||
{ label: 'New database', fn: () => dispatch('newDatabase') },
|
{ label: 'New database…', fn: () => dispatch('newDatabase') },
|
||||||
{ label: 'New collection', fn: () => dispatch('newCollection') },
|
{ label: 'New collection…', fn: () => dispatch('newCollection') },
|
||||||
],
|
],
|
||||||
}))}
|
}))}
|
||||||
actions={[
|
actions={[
|
||||||
@ -99,8 +99,8 @@
|
|||||||
{ icon: '+', fn: evt => {
|
{ icon: '+', fn: evt => {
|
||||||
if (activeDbKey) {
|
if (activeDbKey) {
|
||||||
contextMenu.show(evt, [
|
contextMenu.show(evt, [
|
||||||
{ label: 'New database', fn: () => dispatch('newDatabase') },
|
{ label: 'New database…', fn: () => dispatch('newDatabase') },
|
||||||
{ label: 'New collection', fn: () => dispatch('newCollection') },
|
{ label: 'New collection…', fn: () => dispatch('newCollection') },
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
@ -110,8 +110,8 @@
|
|||||||
{ icon: '-', fn: evt => {
|
{ icon: '-', fn: evt => {
|
||||||
if (activeCollKey) {
|
if (activeCollKey) {
|
||||||
contextMenu.show(evt, [
|
contextMenu.show(evt, [
|
||||||
{ label: 'Drop database', fn: () => dropDatabase(activeDbKey) },
|
{ label: 'Drop database…', fn: () => dropDatabase(activeDbKey) },
|
||||||
{ label: 'Drop collection', fn: () => dropCollection(activeDbKey, activeCollKey) },
|
{ label: 'Drop collection…', fn: () => dropCollection(activeDbKey, activeCollKey) },
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
Loading…
Reference in New Issue
Block a user