Skip to content

Commit

Permalink
String adjustments in SpaceQuota component
Browse files Browse the repository at this point in the history
  • Loading branch information
kulmann committed Feb 18, 2022
1 parent 654a60e commit 1705430
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,17 +18,17 @@ import FileActions from '../../../mixins/fileActions'
import { useIsFilesAppActive } from '../../../composables/useIsFilesAppActive'
export default {
name: 'FileActions',
components: { ActionMenuItem },
mixins: [FileActions],
setup() {
return {
isFilesAppActive: useIsFilesAppActive()
}
},
name: 'FileActions',
title: ($gettext) => {
return $gettext('Actions')
},
components: { ActionMenuItem },
mixins: [FileActions],
computed: {
...mapGetters('Files', ['highlightedFile']),
Expand Down
4 changes: 2 additions & 2 deletions packages/web-app-files/src/components/SpaceQuota.vue
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ export default {
computed: {
spaceStorageDetailsLabel() {
return this.$gettextInterpolate(
this.$gettext('%{used} of %{total} used (%{percentage} % used)'),
this.$gettext('%{used} of %{total} used (%{percentage}% used)'),
{
used: this.quotaUsed,
total: this.quotaTotal,
Expand All @@ -39,7 +39,7 @@ export default {
return filesize(this.spaceQuota.used)
},
quotaUsagePercent() {
return ((this.spaceQuota.used / this.spaceQuota.total) * 100).toFixed(2)
return ((this.spaceQuota.used / this.spaceQuota.total) * 100).toFixed(1)
},
quotaProgressVariant() {
switch (this.spaceQuota.state) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

exports[`SpaceQuota component renders the space storage quota label 1`] = `
<div class="space-quota">
<p class="oc-mb-s oc-mt-rm">1 B of 10 B used (10.00 % used)</p>
<p class="oc-mb-s oc-mt-rm">1 B of 10 B used (10.0% used)</p>
<oc-progress-stub value="10" max="100" size="small" variation="primary"></oc-progress-stub>
</div>
`;

0 comments on commit 1705430

Please sign in to comment.