Style: all - change page padding to 20px

This commit is contained in:
2024-03-15 15:29:52 +08:00
parent de3d1831d0
commit c098368a79
30 changed files with 98 additions and 88 deletions

View File

@@ -2,7 +2,7 @@
[data-component=system] { [data-component=system] {
.root-content { .root-content {
padding: 30px; padding: 20px;
gap: 20px; gap: 20px;
flex-wrap: wrap; flex-wrap: wrap;
justify-content: flex-start; justify-content: flex-start;

View File

@@ -2,7 +2,7 @@
[data-component=system-settings] { [data-component=system-settings] {
.root-content { .root-content {
padding: 30px; padding: 20px;
gap: 20px; gap: 20px;
.root-col { .root-col {

View File

@@ -2,7 +2,7 @@
[data-component=system-statistics] { [data-component=system-statistics] {
.root-content { .root-content {
padding: 30px; padding: 20px;
gap: 20px; gap: 20px;
flex-wrap: wrap; flex-wrap: wrap;
justify-content: center; justify-content: center;

View File

@@ -2,7 +2,7 @@
[data-component=system-tools-base] { [data-component=system-tools-base] {
.root-content { .root-content {
padding: 30px; padding: 20px;
gap: 10px; gap: 10px;
height: 100%; height: 100%;
width: 100%; width: 100%;

View File

@@ -1,5 +1,5 @@
[data-component=system-tools-code] { [data-component=system-tools-code] {
padding: 30px; padding: 20px;
.card-box { .card-box {
width: 100%; width: 100%;

View File

@@ -1,5 +1,5 @@
[data-component=system-tools-execute] { [data-component=system-tools-execute] {
padding: 30px; padding: 20px;
.card-box { .card-box {
width: 100%; width: 100%;

View File

@@ -1,22 +1,29 @@
[data-component=tools-edit] { [data-component=tools-edit] {
.root-content { padding: 20px;
width: 100%;
.card-box {
height: 100%; height: 100%;
width: 100%;
> * { .root-content {
width: 0;
}
.draggable-mask {
position: absolute;
width: 100%; width: 100%;
height: 100%; height: 100%;
> * {
width: 0;
}
.draggable-mask {
position: absolute;
width: 100%;
height: 100%;
}
} }
} }
.draggable-content { .draggable-content {
position: fixed; position: fixed;
inset-inline-end: 32px; inset-inline-end: 48px;
inset-block-end: 48px; inset-block-end: 48px;
> * { > * {

View File

@@ -3,7 +3,7 @@
[data-component=tools] { [data-component=tools] {
.root-content { .root-content {
padding: 30px; padding: 20px;
gap: 20px; gap: 20px;
flex-wrap: wrap; flex-wrap: wrap;
justify-content: flex-start; justify-content: flex-start;

View File

@@ -1,5 +1,5 @@
[data-component=tools-source] { [data-component=tools-source] {
padding: 30px; padding: 20px;
.card-box { .card-box {
width: 100%; width: 100%;

View File

@@ -21,7 +21,7 @@
} }
.root-content { .root-content {
padding: 30px; padding: 20px;
gap: 20px; gap: 20px;
flex-wrap: wrap; flex-wrap: wrap;
justify-content: center; justify-content: center;

View File

@@ -3,9 +3,9 @@
[data-component=tools-store-user] .root-content { [data-component=tools-store-user] .root-content {
padding: { padding: {
top: 80px; top: 80px;
left: 30px; left: 20px;
right: 30px; right: 20px;
bottom: 30px; bottom: 20px;
}; };
.root-box { .root-box {

View File

@@ -1,5 +1,5 @@
[data-component=tools-view] { [data-component=tools-view] {
padding: 30px; padding: 20px;
.card-box { .card-box {
height: 100%; height: 100%;

View File

@@ -3,9 +3,9 @@
[data-component=user] .root-content { [data-component=user] .root-content {
padding: { padding: {
top: 80px; top: 80px;
left: 30px; left: 20px;
right: 30px; right: 20px;
bottom: 30px; bottom: 20px;
}; };
.card-box { .card-box {

View File

@@ -634,7 +634,7 @@ const Group = () => {
<> <>
<FitFullscreen data-component={'system-group'}> <FitFullscreen data-component={'system-group'}>
<HideScrollbar <HideScrollbar
style={{ padding: 30 }} style={{ padding: 20 }}
isShowVerticalScrollbar isShowVerticalScrollbar
autoHideWaitingTime={1000} autoHideWaitingTime={1000}
> >

View File

@@ -285,7 +285,7 @@ const Log = () => {
<> <>
<FitFullscreen> <FitFullscreen>
<HideScrollbar <HideScrollbar
style={{ padding: 30 }} style={{ padding: 20 }}
isShowVerticalScrollbar isShowVerticalScrollbar
autoHideWaitingTime={1000} autoHideWaitingTime={1000}
> >

View File

@@ -641,7 +641,7 @@ const Role = () => {
<> <>
<FitFullscreen> <FitFullscreen>
<HideScrollbar <HideScrollbar
style={{ padding: 30 }} style={{ padding: 20 }}
isShowVerticalScrollbar isShowVerticalScrollbar
autoHideWaitingTime={1000} autoHideWaitingTime={1000}
> >

View File

@@ -286,7 +286,7 @@ const Category = () => {
<> <>
<FitFullscreen data-component={'system-tools-category'}> <FitFullscreen data-component={'system-tools-category'}>
<HideScrollbar <HideScrollbar
style={{ padding: 30 }} style={{ padding: 20 }}
isShowVerticalScrollbar isShowVerticalScrollbar
autoHideWaitingTime={1000} autoHideWaitingTime={1000}
> >

View File

@@ -570,7 +570,7 @@ const Tools = () => {
<> <>
<FitFullscreen> <FitFullscreen>
<HideScrollbar <HideScrollbar
style={{ padding: 30 }} style={{ padding: 20 }}
isShowVerticalScrollbar isShowVerticalScrollbar
autoHideWaitingTime={1000} autoHideWaitingTime={1000}
> >

View File

@@ -1010,7 +1010,7 @@ const User = () => {
<> <>
<FitFullscreen> <FitFullscreen>
<HideScrollbar <HideScrollbar
style={{ padding: 30 }} style={{ padding: 20 }}
isShowVerticalScrollbar isShowVerticalScrollbar
autoHideWaitingTime={1000} autoHideWaitingTime={1000}
> >

View File

@@ -21,6 +21,7 @@ import Playground from '@/components/Playground'
import FitFullscreen from '@/components/common/FitFullscreen' import FitFullscreen from '@/components/common/FitFullscreen'
import FlexBox from '@/components/common/FlexBox' import FlexBox from '@/components/common/FlexBox'
import LoadingMask from '@/components/common/LoadingMask' import LoadingMask from '@/components/common/LoadingMask'
import Card from '@/components/common/Card'
const Edit = () => { const Edit = () => {
const navigate = useNavigate() const navigate = useNavigate()
@@ -403,41 +404,43 @@ const Edit = () => {
return ( return (
<> <>
<FitFullscreen data-component={'tools-edit'}> <FitFullscreen data-component={'tools-edit'}>
<FlexBox direction={'horizontal'} className={'root-content'}> <Card>
<LoadingMask hidden={!loading}> <FlexBox direction={'horizontal'} className={'root-content'}>
<Playground.CodeEditor <LoadingMask hidden={!loading}>
tsconfig={tsconfig} <Playground.CodeEditor
files={{ tsconfig={tsconfig}
...files, files={{
[IMPORT_MAP_FILE_NAME]: { ...files,
name: IMPORT_MAP_FILE_NAME, [IMPORT_MAP_FILE_NAME]: {
language: 'json', name: IMPORT_MAP_FILE_NAME,
value: importMapRaw language: 'json',
}, value: importMapRaw
[TS_CONFIG_FILE_NAME]: { },
name: TS_CONFIG_FILE_NAME, [TS_CONFIG_FILE_NAME]: {
language: 'json', name: TS_CONFIG_FILE_NAME,
value: tsconfigRaw language: 'json',
} value: tsconfigRaw
}} }
notRemovable={[entryPoint]} }}
selectedFileName={selectedFileName} notRemovable={[entryPoint]}
onAddFile={(_, files) => setFiles(files)} selectedFileName={selectedFileName}
onRemoveFile={(_, files) => setFiles(files)} onAddFile={(_, files) => setFiles(files)}
onRenameFile={(_, __, files) => setFiles(files)} onRemoveFile={(_, files) => setFiles(files)}
onChangeFileContent={handleOnChangeFileContent} onRenameFile={(_, __, files) => setFiles(files)}
onSelectedFileChange={setSelectedFileName} onChangeFileContent={handleOnChangeFileContent}
/> onSelectedFileChange={setSelectedFileName}
<Playground.Output />
files={files} <Playground.Output
selectedFileName={selectedFileName} files={files}
importMap={importMap!} selectedFileName={selectedFileName}
entryPoint={entryPoint} importMap={importMap!}
postExpansionCode={baseDist} entryPoint={entryPoint}
/> postExpansionCode={baseDist}
</LoadingMask> />
{showDraggableMask && <div className={'draggable-mask'} />} </LoadingMask>
</FlexBox> {showDraggableMask && <div className={'draggable-mask'} />}
</FlexBox>
</Card>
<Draggable <Draggable
onStart={() => setShowDraggableMask(true)} onStart={() => setShowDraggableMask(true)}
onStop={() => setShowDraggableMask(false)} onStop={() => setShowDraggableMask(false)}