From cfda4e4214f261f86778b4d2674cfcb8419a7572 Mon Sep 17 00:00:00 2001 From: Deep Tailor Date: Wed, 1 Jul 2020 16:20:33 -0700 Subject: [PATCH 1/2] added unnamed folder and required --- src/plugins/newFolderAction/newFolderAction.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/plugins/newFolderAction/newFolderAction.js b/src/plugins/newFolderAction/newFolderAction.js index c93359915d..781aa0af78 100644 --- a/src/plugins/newFolderAction/newFolderAction.js +++ b/src/plugins/newFolderAction/newFolderAction.js @@ -39,7 +39,9 @@ export default class NewFolderAction { key: "name", control: "textfield", name: "Folder Name", - required: false + pattern: "\\S+", + required: true, + cssClass: "l-input-lg" } ] } @@ -53,7 +55,7 @@ export default class NewFolderAction { dialogService = this._openmct.$injector.get('dialogService'), folderType = this._openmct.types.get('folder'); - dialogService.getUserInput(this._dialogForm, {}).then((userInput) => { + dialogService.getUserInput(this._dialogForm, {name: 'Unnamed Folder'}).then((userInput) => { let name = userInput.name, identifier = { key: uuid(), From a9b9107cc3d07ba9ae250fbfaea415ad39b79a30 Mon Sep 17 00:00:00 2001 From: Deep Tailor Date: Wed, 1 Jul 2020 16:30:03 -0700 Subject: [PATCH 2/2] change icon and action name --- src/plugins/newFolderAction/newFolderAction.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/plugins/newFolderAction/newFolderAction.js b/src/plugins/newFolderAction/newFolderAction.js index 781aa0af78..fcc12b95e2 100644 --- a/src/plugins/newFolderAction/newFolderAction.js +++ b/src/plugins/newFolderAction/newFolderAction.js @@ -24,14 +24,14 @@ import uuid from 'uuid'; export default class NewFolderAction { constructor(openmct) { - this.name = 'New Folder'; + this.name = 'Add New Folder'; this.key = 'newFolder'; this.description = 'Create a new folder'; - this.cssClass = 'icon-folder'; + this.cssClass = 'icon-folder-new'; this._openmct = openmct; this._dialogForm = { - name: "New Folder Name", + name: "Add New Folder", sections: [ { rows: [