This commit is contained in:
Liyas Thomas
2020-09-24 21:37:27 +05:30
33 changed files with 251 additions and 471 deletions

View File

@@ -7,36 +7,6 @@ export const SETTINGS_KEYS = [
*/
"SCROLL_INTO_ENABLED",
/**
* The CSS class that should be applied to the root element.
* Essentially, the name of the background theme.
*/
"THEME_CLASS",
/**
* The hex color code for the currently active theme.
*/
"THEME_COLOR",
/**
* The hex color code for browser tab color.
*/
"THEME_TAB_COLOR",
/**
* Whether or not THEME_COLOR is considered 'vibrant'.
*
* For readability reasons, if the THEME_COLOR is vibrant,
* any text placed on the theme color will have its color
* inverted from white to black.
*/
"THEME_COLOR_VIBRANT",
/**
* The Ace editor theme
*/
"THEME_ACE_EDITOR",
/**
* Normally, section frames are multicolored in the UI
* to emphasise the different sections.
@@ -331,9 +301,12 @@ export const mutations = {
const { request } = payload
// Remove the old request from collection
if (Object.prototype.hasOwnProperty.call(request, "oldCollection") && request.oldCollection > -1) {
if (
Object.prototype.hasOwnProperty.call(request, "oldCollection") &&
request.oldCollection > -1
) {
const folder =
Object.prototype.hasOwnProperty.call(request, "oldFolder") && request.oldFolder >= -1
Object.prototype.hasOwnProperty.call(request, "oldFolder") && request.oldFolder >= -1
? request.oldFolder
: request.folder
if (folder > -1) {
@@ -341,7 +314,10 @@ export const mutations = {
} else {
collections[request.oldCollection].requests.splice(request.requestIndex, 1)
}
} else if (Object.prototype.hasOwnProperty.call(request, "oldFolder") && request.oldFolder !== -1) {
} else if (
Object.prototype.hasOwnProperty.call(request, "oldFolder") &&
request.oldFolder !== -1
) {
collections[request.collection].folders[folder].requests.splice(request.requestIndex, 1)
}