功能:适配网站管理移动端

This commit is contained in:
Liu 宇阳
2024-11-11 12:44:13 +08:00
parent 1b121b7c1d
commit 304b43e563
2 changed files with 7 additions and 8 deletions

View File

@@ -1,8 +1,9 @@
.WebPage { .WebPage {
.list { .list {
display: flex; display: grid;
flex-wrap: wrap; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
justify-content: center; gap: 20px;
justify-items: center;
min-height: 100px; min-height: 100px;
margin-top: 40px; margin-top: 40px;
@@ -15,8 +16,6 @@
width: 200px; width: 200px;
height: 250px; height: 250px;
padding: 0px 20px; padding: 0px 20px;
margin-right: 50px;
margin-bottom: 20px;
border: 1px solid #eee; border: 1px solid #eee;
border-radius: 5px; border-radius: 5px;
background-color: #fff; background-color: #fff;

View File

@@ -120,7 +120,7 @@ const LinkPage = () => {
<div className="list"> <div className="list">
{listTemp.length > 0 ? ( {listTemp.length > 0 ? (
listTemp.map(item => ( listTemp.map(item => (
<div key={item.id} className={`item`}> <div key={item.id} className="item">
<div className="avatar"> <div className="avatar">
<img src={item.image} alt="" className="avatar-img" /> <img src={item.image} alt="" className="avatar-img" />
</div> </div>
@@ -155,7 +155,7 @@ const LinkPage = () => {
<> <>
<h2 className="text-xl pb-4 text-center">{isMethod === "edit" ? '编辑网站' : '新增网站'}</h2> <h2 className="text-xl pb-4 text-center">{isMethod === "edit" ? '编辑网站' : '新增网站'}</h2>
<div className='w-5/12 mx-auto'> <div className='w-full md:w-[500px] mx-auto'>
<Form form={form} layout="vertical" size='large' initialValues={link} onFinish={submit}> <Form form={form} layout="vertical" size='large' initialValues={link} onFinish={submit}>
<Form.Item label="网站标题" name="title" rules={[{ required: true, message: '网站标题不能为空' }]}> <Form.Item label="网站标题" name="title" rules={[{ required: true, message: '网站标题不能为空' }]}>
<Input placeholder="Thrive" /> <Input placeholder="Thrive" />