fat: 栅格系统

This commit is contained in:
wf 2024-05-20 13:03:51 +08:00
parent 52de98e203
commit 440b9007fb
6 changed files with 41 additions and 15 deletions

View File

@ -1,4 +1,2 @@
#!/usr/bin/env sh #!/usr/bin/env sh
. "$(dirname -- "$0")/husky.sh" . "${0%/*}/h"
npx --no-install commitlint --edit $1

View File

@ -1,5 +1,2 @@
#!/bin/sh #!/usr/bin/env sh
. "${0%/*}/h"
. "$(dirname "$0")/husky.sh"
npm run lint-staged

8
pnpm-lock.yaml generated
View File

@ -1,9 +1,5 @@
lockfileVersion: '6.0' lockfileVersion: '6.0'
settings:
autoInstallPeers: true
excludeLinksFromLockfile: false
dependencies: dependencies:
'@arco-design/color': '@arco-design/color':
specifier: ^0.4.0 specifier: ^0.4.0
@ -6027,3 +6023,7 @@ packages:
resolution: {integrity: sha512-9bnSc/HEW2uRy67wc+T8UwauLuPJVn28jb+GtJY16iiKWyvmYJRXVT4UamsAEGQfPohgr2q4Tq0sQbQlxTfi1g==} resolution: {integrity: sha512-9bnSc/HEW2uRy67wc+T8UwauLuPJVn28jb+GtJY16iiKWyvmYJRXVT4UamsAEGQfPohgr2q4Tq0sQbQlxTfi1g==}
engines: {node: '>=12.20'} engines: {node: '>=12.20'}
dev: true dev: true
settings:
autoInstallPeers: true
excludeLinksFromLockfile: false

View File

@ -1,6 +1,6 @@
<template> <template>
<a-menu <a-menu
:breakpoint="layoutType === 'layoutDefaults' ? undefined : 'xl'" :breakpoint="layoutType != 'layoutHead' ? 'xl' : undefined"
:mode="'vertical'" :mode="'vertical'"
:theme="asideDark ? 'dark' : 'light'" :theme="asideDark ? 'dark' : 'light'"
:collapsed="collapsed" :collapsed="collapsed"

View File

@ -25,6 +25,18 @@ onMounted(() => {
// loading // loading
loadingPage.done(200); loadingPage.done(200);
}); });
//
onBeforeMount(() => {
onLayoutResize();
window.addEventListener("resize", onLayoutResize);
});
//
const onLayoutResize = () => {
let clientWidth = document.body.clientWidth;
console.log("窗口大小", clientWidth);
};
</script> </script>
<style lang="scss" scoped></style> <style lang="scss" scoped></style>

View File

@ -8,14 +8,33 @@
</div> </div>
</div> </div>
<a-divider :margin="16" /> <a-divider :margin="16" />
<div class="flex-row-between-center"> <!-- <div class="flex-row-between-center">
<div v-for="(item, index) in shortcut" :key="item.id" class="card-middling row-center" :class="'animated-fade-up-' + index"> <div v-for="(item, index) in shortcut" :key="item.id" class="card-middling row-center" :class="'animated-fade-up-' + index">
<div> <div>
<SvgIcon :name="item.svg" :size="40" /> <SvgIcon :name="item.svg" :size="40" />
<span class="shortcut-card-label">{{ item.name }}</span> <span class="shortcut-card-label">{{ item.name }}</span>
</div> </div>
</div> </div>
</div> -->
<a-row class="grid-demo">
<a-col
:xs="24"
:sm="12"
:md="12"
:lg="8"
:xl="4"
:xxl="4"
v-for="(item, index) in shortcut"
:key="item.id"
class="card-middling row-center"
:class="'animated-fade-up-' + index"
>
<div>
<SvgIcon :name="item.svg" :size="40" />
<span class="shortcut-card-label">{{ item.name }}</span>
</div> </div>
</a-col>
</a-row>
</div> </div>
</template> </template>