css布局之flex应用


css 复制代码
		/*父  100*/
        .parent-div {
            /* 这里添加你想要的属性 */
            display: flex;
            flex-direction: row; //行
            justify-content: space-between; //左右对齐
            align-items: center;
            flex-wrap: wrap; //换行
        }
		/*中 90 +10 */
        .middle-div {
            /* 这里添加你想要的属性 */
            display: flex;
            flex-direction: row;
			align-items: center;
            flex-wrap: wrap;
        }
		/*子 每一个小div */
        .son-div {
            /* 这里添加你想要的属性 */
            flex-direction: row;
			margin: 5px 10px;
        }
        
html 复制代码
<div class="form-group parent-div"   >

                    <div class="middle-div" style="width: 90%; justify-content: left;">
                        <div class="son-div">
                            <a  class="search-button"  >导出</a>
                        </div>
                        <div class="son-div">
                            <input type="text" id="dc_ids"   class="form-control" style="width: 185px;" >
                        </div>                         
                    </div>


                    <div class="middle-div"  style="width: 10%;justify-content: right;flex-direction: row">
                        <div class="son-div">
                            <a  class="search-button"  >读卡</a>
                        </div>
                        <div class="son-div">
                            <a  class="search-button"  >查询</a>
                        </div>

                    </div>

                </div>
相关推荐
Moment17 分钟前
Cursor 2.0 支持模型并发,我用国产 RWKV 模型实现了一模一样的效果 🤩🤩🤩
前端·后端·openai
狂炫冰美式26 分钟前
QuizPort 1.0 · 让每篇好文都有测验陪跑
前端·后端·面试
咋吃都不胖lyh1 小时前
.docx 和 .doc 是 Microsoft Word 文档的两种主要文件格式
前端·html·xhtml
哈乐1 小时前
网工应用题:配置命令补全类题目
服务器·前端·网络
uuai1 小时前
echarts不同版本显示不一致问题
前端·javascript·echarts
AKclown1 小时前
基于Monaco的diffEditor实现内容对比
前端·vue.js·react.js
摆烂工程师1 小时前
(2025年11月)开发了 ChatGPT 导出聊天记录的插件,ChatGPT Free、Plus、Business、Team 等用户都可用
前端·后端·程序员
gongzemin2 小时前
使用阿里云ECS部署前端应用
前端·vue.js·后端
用户41180034153412 小时前
Flutter课题汇报
前端
环信2 小时前
实战教程|快速上线音视频通话:手把手教你实现呼叫与接听全流程
前端