diff --git a/@vates/task/index.js b/@vates/task/index.js index d8a78bb13d..c66b44669a 100644 --- a/@vates/task/index.js +++ b/@vates/task/index.js @@ -130,7 +130,7 @@ exports.Task = class Task { return true } - return false; + return false } async run(fn) { diff --git a/@xen-orchestra/lite/src/assets/reset.css b/@xen-orchestra/lite/src/assets/reset.css index 8b386eb345..2d706f7814 100644 --- a/@xen-orchestra/lite/src/assets/reset.css +++ b/@xen-orchestra/lite/src/assets/reset.css @@ -12,13 +12,23 @@ html { font-family: Poppins, sans-serif; } -body, h1, h2, h3, h4, h5, h6, p, ol, ul { +body, +h1, +h2, +h3, +h4, +h5, +h6, +p, +ol, +ul { margin: 0; padding: 0; font-weight: normal; } -ol, ul { +ol, +ul { list-style: none; } diff --git a/@xen-orchestra/lite/src/assets/theme.css b/@xen-orchestra/lite/src/assets/theme.css index e256b13726..1d34b2de31 100644 --- a/@xen-orchestra/lite/src/assets/theme.css +++ b/@xen-orchestra/lite/src/assets/theme.css @@ -1,75 +1,85 @@ :root { --color-blue-scale-000: #000000; - --color-blue-scale-100: #1A1B38; - --color-blue-scale-200: #595A6F; - --color-blue-scale-300: #9899A5; - --color-blue-scale-400: #E5E5E7; - --color-blue-scale-500: #FFFFFF; + --color-blue-scale-100: #1a1b38; + --color-blue-scale-200: #595a6f; + --color-blue-scale-300: #9899a5; + --color-blue-scale-400: #e5e5e7; + --color-blue-scale-500: #ffffff; - --color-extra-blue-l60: #D1CEFB; - --color-extra-blue-l40: #BBB5F9; - --color-extra-blue-l20: #A39DF8; - --color-extra-blue-base: #8F84FF; - --color-extra-blue-d20: #716AC6; - --color-extra-blue-d40: #554F94; + --color-extra-blue-l60: #d1cefb; + --color-extra-blue-l40: #bbb5f9; + --color-extra-blue-l20: #a39df8; + --color-extra-blue-base: #8f84ff; + --color-extra-blue-d20: #716ac6; + --color-extra-blue-d40: #554f94; --color-extra-blue-d60: #383563; - --color-green-infra-l60: #B5DBCA; - --color-green-infra-l40: #91C9B0; - --color-green-infra-l20: #70B795; - --color-green-infra-base: #55A57B; + --color-green-infra-l60: #b5dbca; + --color-green-infra-l40: #91c9b0; + --color-green-infra-l20: #70b795; + --color-green-infra-base: #55a57b; --color-green-infra-d20: #438463; - --color-green-infra-d40: #32634A; + --color-green-infra-d40: #32634a; --color-green-infra-d60: #214231; - --color-orange-world-l60: #F2CDA8; - --color-orange-world-l40: #EBB57D; - --color-orange-world-l20: #E59D56; - --color-orange-world-base: #EF7F18; - --color-orange-world-d20: #BF6612; - --color-orange-world-d40: #864F1F; - --color-orange-world-d60: #5A3514; + --color-orange-world-l60: #f2cda8; + --color-orange-world-l40: #ebb57d; + --color-orange-world-l20: #e59d56; + --color-orange-world-base: #ef7f18; + --color-orange-world-d20: #bf6612; + --color-orange-world-d40: #864f1f; + --color-orange-world-d60: #5a3514; - --color-red-vates-l60: #DDA5A7; - --color-red-vates-l40: #CE787C; - --color-red-vates-l20: #BF4F51; - --color-red-vates-base: #BE1621; - --color-red-vates-d20: #8E2221; - --color-red-vates-d40: #6A1919; + --color-red-vates-l60: #dda5a7; + --color-red-vates-l40: #ce787c; + --color-red-vates-l20: #bf4f51; + --color-red-vates-base: #be1621; + --color-red-vates-d20: #8e2221; + --color-red-vates-d40: #6a1919; --color-red-vates-d60: #471010; --color-grayscale-200: #585757; - --background-color-primary: #FFFFFF; - --background-color-secondary: #F6F6F7; - --background-color-extra-blue: #F4F3FE; - --background-color-green-infra: #ECF5F2; - --background-color-orange-world: #FBF2E9; - --background-color-red-vates: #F5E8E9; + --background-color-primary: #ffffff; + --background-color-secondary: #f6f6f7; + --background-color-extra-blue: #f4f3fe; + --background-color-green-infra: #ecf5f2; + --background-color-orange-world: #fbf2e9; + --background-color-red-vates: #f5e8e9; --shadow-100: 0 0.1rem 0.1rem rgba(20, 20, 30, 0.06); - --shadow-200: 0 0.1rem 0.3rem rgba(20, 20, 30, 0.1), 0 0.2rem 0.1rem rgba(20, 20, 30, 0.06), 0 0.1rem 0.1rem rgba(20, 20, 30, 0.08); - --shadow-300: 0 0.3rem 0.5rem rgba(20, 20, 30, 0.1), 0 0.1rem 1.8rem rgba(20, 20, 30, 0.06), 0 0.6rem 1.0rem rgba(20, 20, 30, 0.08); - --shadow-400: 0 1.1rem 1.5rem rgba(20, 20, 30, 0.1), 0 0.9rem 4.6rem rgba(20, 20, 30, 0.06), 0 2.4rem 3.8rem rgba(20, 20, 30, 0.04); + --shadow-200: 0 0.1rem 0.3rem rgba(20, 20, 30, 0.1), + 0 0.2rem 0.1rem rgba(20, 20, 30, 0.06), + 0 0.1rem 0.1rem rgba(20, 20, 30, 0.08); + --shadow-300: 0 0.3rem 0.5rem rgba(20, 20, 30, 0.1), + 0 0.1rem 1.8rem rgba(20, 20, 30, 0.06), 0 0.6rem 1rem rgba(20, 20, 30, 0.08); + --shadow-400: 0 1.1rem 1.5rem rgba(20, 20, 30, 0.1), + 0 0.9rem 4.6rem rgba(20, 20, 30, 0.06), + 0 2.4rem 3.8rem rgba(20, 20, 30, 0.04); } :root.dark { - --color-blue-scale-000: #FFFFFF; - --color-blue-scale-100: #E5E5E7; - --color-blue-scale-200: #9899A5; - --color-blue-scale-300: #595A6F; - --color-blue-scale-400: #1A1B38; + --color-blue-scale-000: #ffffff; + --color-blue-scale-100: #e5e5e7; + --color-blue-scale-200: #9899a5; + --color-blue-scale-300: #595a6f; + --color-blue-scale-400: #1a1b38; --color-blue-scale-500: #000000; - --background-color-primary: #14141D; - --background-color-secondary: #17182A; - --background-color-extra-blue: #35335D; - --background-color-green-infra: #243B3D; + --background-color-primary: #14141d; + --background-color-secondary: #17182a; + --background-color-extra-blue: #35335d; + --background-color-green-infra: #243b3d; --background-color-orange-world: #493328; - --background-color-red-vates: #3C1A28; + --background-color-red-vates: #3c1a28; --shadow-100: 0 0.1rem 0.1rem rgba(20, 20, 30, 0.12); - --shadow-200: 0 0.1rem 0.3rem rgba(20, 20, 30, 0.2), 0 0.2rem 0.1rem rgba(20, 20, 30, 0.12), 0 0.1rem 0.1rem rgba(20, 20, 30, 0.16); - --shadow-300: 0 0.3rem 0.5rem rgba(20, 20, 30, 0.2), 0 0.1rem 1.8rem rgba(20, 20, 30, 0.12), 0 0.6rem 1.0rem rgba(20, 20, 30, 0.16); - --shadow-400: 0 1.1rem 1.5rem rgba(20, 20, 30, 0.2), 0 0.9rem 4.6rem rgba(20, 20, 30, 0.12), 0 2.4rem 3.8rem rgba(20, 20, 30, 0.08); + --shadow-200: 0 0.1rem 0.3rem rgba(20, 20, 30, 0.2), + 0 0.2rem 0.1rem rgba(20, 20, 30, 0.12), + 0 0.1rem 0.1rem rgba(20, 20, 30, 0.16); + --shadow-300: 0 0.3rem 0.5rem rgba(20, 20, 30, 0.2), + 0 0.1rem 1.8rem rgba(20, 20, 30, 0.12), 0 0.6rem 1rem rgba(20, 20, 30, 0.16); + --shadow-400: 0 1.1rem 1.5rem rgba(20, 20, 30, 0.2), + 0 0.9rem 4.6rem rgba(20, 20, 30, 0.12), + 0 2.4rem 3.8rem rgba(20, 20, 30, 0.08); } diff --git a/@xen-orchestra/lite/src/composables/array-removed-items-history.composable.md b/@xen-orchestra/lite/src/composables/array-removed-items-history.composable.md index e04621701d..d313447d6d 100644 --- a/@xen-orchestra/lite/src/composables/array-removed-items-history.composable.md +++ b/@xen-orchestra/lite/src/composables/array-removed-items-history.composable.md @@ -6,10 +6,10 @@ This composable allows you to keep a history of each removed item of an array. ```typescript const myArray = ref([]); -const history = useArrayRemovedItemsHistory(myArray) +const history = useArrayRemovedItemsHistory(myArray); -myArray.push('A'); // myArray = ['A']; history = [] -myArray.push('B'); // myArray = ['A', 'B']; history = [] +myArray.push("A"); // myArray = ['A']; history = [] +myArray.push("B"); // myArray = ['A', 'B']; history = [] myArray.shift(); // myArray = ['B']; history = ['A'] ``` @@ -25,8 +25,8 @@ Be careful when using an array of objects which is likely to be replaced (instea ```typescript const myArray = ref([]); const history = useArrayRemovedItemsHistory(myArray); -myArray.value = [{ id: 'foo' }, { id: 'bar' }]; -myArray.value = [{ id: 'bar' }, { id: 'baz' }]; // history = [{ id: 'foo' }, { id: 'bar' }] +myArray.value = [{ id: "foo" }, { id: "bar" }]; +myArray.value = [{ id: "bar" }, { id: "baz" }]; // history = [{ id: 'foo' }, { id: 'bar' }] ``` In this case, `{ id: 'bar' }` is detected as removed since in JavaScript `{ id: 'bar' } !== { id: 'bar' }`. @@ -35,7 +35,11 @@ You must therefore use an identity function as third parameter to return the val ```typescript const myArray = ref<{ id: string }[]>([]); -const history = useArrayRemovedItemsHistory(myArray, undefined, (item) => item.id); -myArray.value = [{ id: 'foo' }, { id: 'bar' }]; -myArray.value = [{ id: 'bar' }, { id: 'baz' }]; // history = [{ id: 'foo' }] +const history = useArrayRemovedItemsHistory( + myArray, + undefined, + (item) => item.id +); +myArray.value = [{ id: "foo" }, { id: "bar" }]; +myArray.value = [{ id: "bar" }, { id: "baz" }]; // history = [{ id: 'foo' }] ``` diff --git a/@xen-orchestra/lite/src/locales/en.json b/@xen-orchestra/lite/src/locales/en.json index 0ba270a842..f07e0644ce 100644 --- a/@xen-orchestra/lite/src/locales/en.json +++ b/@xen-orchestra/lite/src/locales/en.json @@ -30,7 +30,7 @@ "do-you-have-needs": "You have needs and/or expectations? Let us know", "edit-config": "Edit config", "error-no-data": "Error, can't collect data.", - "error-occured": "An error has occurred", + "error-occured": "An error has occurred", "export": "Export", "export-table-to": "Export table to {type}", "export-vms": "Export VMs", diff --git a/@xen-orchestra/xapi/_parseDateTime.test.js b/@xen-orchestra/xapi/_parseDateTime.test.js index b6c85ffb75..04c2971ce7 100644 --- a/@xen-orchestra/xapi/_parseDateTime.test.js +++ b/@xen-orchestra/xapi/_parseDateTime.test.js @@ -26,14 +26,14 @@ test('parseDateTime()', function () { } }) -test('failing parseDateTime()' , function(){ - for (const [input, error] of [ +test('failing parseDateTime()', function () { + for (const [input, error] of [ // object [{}, TypeError], [undefined, TypeError], // string - ['XXX 03/10/2010', RangeError] + ['XXX 03/10/2010', RangeError], ]) { assert.throws(() => parseDateTime(input), error) } diff --git a/book.json b/book.json index d51ffdce09..56db954a27 100644 --- a/book.json +++ b/book.json @@ -1,9 +1,6 @@ { "gitbook": ">=3.0.0", "root": "./docs", - "plugins": [ - "anchors", - "-edit-link" - ], + "plugins": ["anchors", "-edit-link"], "pluginsConfig": {} } diff --git a/docs/users.md b/docs/users.md index efcfbf468e..111970f89e 100644 --- a/docs/users.md +++ b/docs/users.md @@ -113,7 +113,7 @@ Save the configuration and then activate the plugin (button on top). This plugin allows any GitHub user to authenticate to Xen-Orchestra. -The first time a user signs in, XO will create a new XO user with the same identifier (i.e. GitHub name), with *user* permissions. An existing admin will need to apply the appropriate permissions for your environment. +The first time a user signs in, XO will create a new XO user with the same identifier (i.e. GitHub name), with _user_ permissions. An existing admin will need to apply the appropriate permissions for your environment. First you need to configure a new app in your GitHub account: @@ -122,7 +122,7 @@ First you need to configure a new app in your GitHub account: Go to your Github settings > "Developer Settings" > "OAuth Apps" > "New OAuth App". 1. Name your GitHub application under "Application Name". -2. Enter your Xen Orchestra URL (or IP) under "Homepage URL" +2. Enter your Xen Orchestra URL (or IP) under "Homepage URL" 3. Add your "Authorization callback URL" (for example, https://homepageUrl/signin/github/callback) When you get your `clientID` and your `clientSecret`, you can configure them in the GitHub Plugin inside the "Settings/Plugins" view of Xen Orchestra. diff --git a/packages/xo-web/src/chartist.scss b/packages/xo-web/src/chartist.scss index c76da62dd0..9f1cfff6b0 100644 --- a/packages/xo-web/src/chartist.scss +++ b/packages/xo-web/src/chartist.scss @@ -1,4 +1,3 @@ - // CHARTIST =================================================================== $ct-series-colors: ( @@ -19,8 +18,8 @@ $ct-series-colors: ( #a748ca ) !default; -@import "../../../node_modules/chartist/dist/scss/settings/_chartist-settings"; -@import "../../../node_modules/chartist/dist/scss/chartist"; +@import '../../../node_modules/chartist/dist/scss/settings/_chartist-settings'; +@import '../../../node_modules/chartist/dist/scss/chartist'; .ct-chart { display: flex; @@ -45,11 +44,11 @@ $ct-series-colors: ( .ct-point { stroke-width: 30px; - stroke-opacity: 0!important; + stroke-opacity: 0 !important; } .ct-point:hover { - stroke-opacity: 0.2!important; + stroke-opacity: 0.2 !important; stroke-width: 20px; } diff --git a/packages/xo-web/src/common/action-row-button/index.css b/packages/xo-web/src/common/action-row-button/index.css index e236585958..8308e7f77e 100644 --- a/packages/xo-web/src/common/action-row-button/index.css +++ b/packages/xo-web/src/common/action-row-button/index.css @@ -2,6 +2,7 @@ opacity: 0.5; } -tr:hover .button, tr:focus .button { +tr:hover .button, +tr:focus .button { opacity: 1; } diff --git a/packages/xo-web/src/common/dropzone/index.css b/packages/xo-web/src/common/dropzone/index.css index 7b195906a7..80ba347e1a 100644 --- a/packages/xo-web/src/common/dropzone/index.css +++ b/packages/xo-web/src/common/dropzone/index.css @@ -1,22 +1,22 @@ @value dropzoneColor: #8f8686; .dropzone { - border-radius: 4px; - border: 2px dashed dropzoneColor; - cursor: pointer; - display: flex; - height: 12em; - margin-bottom: 20px; - width: 100%; + border-radius: 4px; + border: 2px dashed dropzoneColor; + cursor: pointer; + display: flex; + height: 12em; + margin-bottom: 20px; + width: 100%; } .activeDropzone { - background: #f0f0f0; - border-style: solid; + background: #f0f0f0; + border-style: solid; } .dropzoneText { - color: dropzoneColor; - font-size: 1.2em; - margin: auto; + color: dropzoneColor; + font-size: 1.2em; + margin: auto; } diff --git a/packages/xo-web/src/common/wizard/index.css b/packages/xo-web/src/common/wizard/index.css index d87bda53bf..21bbd52334 100644 --- a/packages/xo-web/src/common/wizard/index.css +++ b/packages/xo-web/src/common/wizard/index.css @@ -39,7 +39,7 @@ /* Bulleted list */ .bullet { - position:relative; + position: relative; margin-bottom: 0; } .bullet:after { diff --git a/packages/xo-web/src/common/xo-week-charts/index.css b/packages/xo-web/src/common/xo-week-charts/index.css index 8b953b9aec..5bfbb7c6f9 100644 --- a/packages/xo-web/src/common/xo-week-charts/index.css +++ b/packages/xo-web/src/common/xo-week-charts/index.css @@ -1,3 +1,3 @@ .container { - width: 100%; + width: 100%; } diff --git a/packages/xo-web/src/common/xo-week-heatmap/index.css b/packages/xo-web/src/common/xo-week-heatmap/index.css index 3e6a745444..5c317e05f5 100644 --- a/packages/xo-web/src/common/xo-week-heatmap/index.css +++ b/packages/xo-web/src/common/xo-week-heatmap/index.css @@ -1,13 +1,13 @@ .cell { - border-radius: 4px; - height: 2em; - padding: 1px; - transition: background-color 300ms linear; + border-radius: 4px; + height: 2em; + padding: 1px; + transition: background-color 300ms linear; } .table { - border-spacing: 2px; - border-collapse: separate; - table-layout: fixed; - width: 100%; + border-spacing: 2px; + border-collapse: separate; + table-layout: fixed; + width: 100%; } diff --git a/packages/xo-web/src/common/xo/migrate-vm-modal/index.css b/packages/xo-web/src/common/xo/migrate-vm-modal/index.css index 013f70502a..c664b38914 100644 --- a/packages/xo-web/src/common/xo/migrate-vm-modal/index.css +++ b/packages/xo-web/src/common/xo/migrate-vm-modal/index.css @@ -1,6 +1,6 @@ .listTitle { font-weight: bold; - font-size: 1.1em + font-size: 1.1em; } .listItem { diff --git a/packages/xo-web/src/icons.scss b/packages/xo-web/src/icons.scss index 1407b53bd5..5981457369 100644 --- a/packages/xo-web/src/icons.scss +++ b/packages/xo-web/src/icons.scss @@ -347,7 +347,6 @@ @extend .fa-circle-thin; } - // Backups &-backup { @extend .fa; @@ -685,7 +684,6 @@ } } - // Host and VM actions &-host, &-vm { diff --git a/packages/xo-web/src/meter.scss b/packages/xo-web/src/meter.scss index a57f575940..f740c27382 100644 --- a/packages/xo-web/src/meter.scss +++ b/packages/xo-web/src/meter.scss @@ -6,45 +6,45 @@ // error for usage > 90% meter { - /* For Firefox */ - background: #EEE; - box-shadow: 0 2px 3px rgba(0,0,0,0.2) inset; - border-radius: 3px; + /* For Firefox */ + background: #eee; + box-shadow: 0 2px 3px rgba(0, 0, 0, 0.2) inset; + border-radius: 3px; } meter::-webkit-meter-bar { - background: #EEE; - box-shadow: 0 2px 3px rgba(0,0,0,0.2) inset; - border-radius: 3px; + background: #eee; + box-shadow: 0 2px 3px rgba(0, 0, 0, 0.2) inset; + border-radius: 3px; } meter::-webkit-meter-optimum-value { - background: $brand-success; - border-radius: 3px; + background: $brand-success; + border-radius: 3px; } meter::-webkit-meter-suboptimum-value { - background: $brand-warning; - border-radius: 3px; + background: $brand-warning; + border-radius: 3px; } meter::-webkit-meter-even-less-good-value { - background: $brand-danger; - border-radius: 3px; + background: $brand-danger; + border-radius: 3px; } meter::-moz-meter-bar { - border-radius: 3px; + border-radius: 3px; } meter:-moz-meter-optimum::-moz-meter-bar { - background: $brand-success; + background: $brand-success; } meter:-moz-meter-sub-optimum::-moz-meter-bar { - background: $brand-warning; + background: $brand-warning; } meter:-moz-meter-sub-sub-optimum::-moz-meter-bar { - background: $brand-danger; + background: $brand-danger; } diff --git a/packages/xo-web/src/xo-app/dashboard/overview/index.css b/packages/xo-web/src/xo-app/dashboard/overview/index.css index 463ea7b330..0600ec10ca 100644 --- a/packages/xo-web/src/xo-app/dashboard/overview/index.css +++ b/packages/xo-web/src/xo-app/dashboard/overview/index.css @@ -1,4 +1,4 @@ .bigCardContent { - font-size: 4em; - text-align: center; + font-size: 4em; + text-align: center; } diff --git a/packages/xo-web/src/xo-app/home/index.css b/packages/xo-web/src/xo-app/home/index.css index d011e4501e..0f0f10b23a 100644 --- a/packages/xo-web/src/xo-app/home/index.css +++ b/packages/xo-web/src/xo-app/home/index.css @@ -4,7 +4,7 @@ .itemContainer { border: 1px solid #eee; - border-radius: .3em; + border-radius: 0.3em; } .itemContainerHeader { @@ -42,7 +42,7 @@ color: #999; font-size: 1em; text-overflow: ellipsis; - white-space:nowrap; + white-space: nowrap; } .itemExpandButton {