Skip to content

Commit

Permalink
update layout
Browse files Browse the repository at this point in the history
  • Loading branch information
Nikita-Polyakov committed Mar 5, 2024
1 parent 6372fc6 commit 82c88f4
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 8 deletions.
17 changes: 15 additions & 2 deletions src/components/shared/Widget/Grid/Grid.vue
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
:breakpoints="breakpoints"
:row-height="rowHeight"
:is-draggable="true"
:is-resizable="false"
:is-resizable="true"
:is-mirrored="false"
:responsive="true"
:vertical-compact="verticalCompact"
Expand Down Expand Up @@ -69,7 +69,7 @@ const DEFAULT_COLS = {
export default class WidgetsGrid extends Vue {
@Prop({ required: true, type: Object }) readonly layouts!: any;
@Prop({ default: 12, type: Number }) readonly columns!: number;
@Prop({ default: 30, type: Number }) readonly rowHeight!: number;
@Prop({ default: 10, type: Number }) readonly rowHeight!: number;
@Prop({ default: 16, type: Number }) readonly margin!: number;
@Prop({ default: true, type: Boolean }) readonly verticalCompact!: boolean;
@Prop({ default: () => DEFAULT_COLS, type: Object }) readonly cols!: any;
Expand Down Expand Up @@ -130,3 +130,16 @@ export default class WidgetsGrid extends Vue {
}
}
</script>

<style lang="scss">
.grid-wrapper {
.grid-item {
display: flex;
flex-flow: column nowrap;
.base-widget {
flex: 1;
}
}
}
</style>
12 changes: 6 additions & 6 deletions src/views/Swap.vue
Original file line number Diff line number Diff line change
Expand Up @@ -53,15 +53,15 @@ export default class Swap extends Mixins(mixins.LoadingMixin, TranslationMixin,
layouts = {
lg: [
{ x: 0, y: 0, w: 6, h: 15, i: 'form' },
{ x: 6, y: 0, w: 12, h: 15, i: 'chart' },
{ x: 6, y: 0, w: 18, h: 15, i: 'chart' },
{ x: 0, y: 15, w: 6, h: 10, i: 'distribution' },
{ x: 18, y: 0, w: 6, h: 15, i: 'transactions' },
{ x: 6, y: 15, w: 12, h: 15, i: 'transactions' },
],
md: [
{ x: 0, y: 0, w: 4, h: 12, i: 'form' },
{ x: 4, y: 0, w: 8, h: 12, i: 'chart' },
{ x: 0, y: 12, w: 4, h: 10, i: 'distribution' },
{ x: 4, y: 12, w: 8, h: 14, i: 'transactions' },
{ x: 0, y: 0, w: 4, h: 20, i: 'form' },
{ x: 4, y: 0, w: 8, h: 20, i: 'chart' },
{ x: 0, y: 20, w: 4, h: 12, i: 'distribution' },
{ x: 4, y: 20, w: 8, h: 24, i: 'transactions' },
],
};
Expand Down
9 changes: 9 additions & 0 deletions vue.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,15 @@ module.exports = defineConfig({
attrs: ['test', 'testid', 'test-name'],
},
},
devServer: {
client: {
overlay: {
errors: true,
warnings: false,
runtimeErrors: false,
},
},
},
productionSourceMap: false,
runtimeCompiler: true,
});

0 comments on commit 82c88f4

Please sign in to comment.