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>
相关推荐
go2coding16 分钟前
开源 复刻GPT-4o - Moshi;自动定位和解决软件开发中的问题;ComfyUI中使用MimicMotion;自动生成React前端代码
前端·react.js·前端框架
freesharer35 分钟前
Zabbix 配置WEB监控
前端·数据库·zabbix
web前端神器36 分钟前
forever启动后端服务,自带日志如何查看与设置
前端·javascript·vue.js
是Yu欸41 分钟前
【前端实现】在父组件中调用公共子组件:注意事项&逻辑示例 + 将后端数组数据格式转换为前端对象数组形式 + 增加和删除行
前端·vue.js·笔记·ui·vue
今天是 几 号1 小时前
WEB攻防-XSS跨站&反射型&存储型&DOM型&标签闭合&输入输出&JS代码解析
前端·javascript·xss
A-超1 小时前
html5 video去除边框
前端·html·html5
进击的阿三姐1 小时前
vue2项目迁移vue3与gogocode的使用
前端·javascript·vue.js
hawk2014bj2 小时前
React 打包时如何关闭源代码混淆
前端·react.js·前端框架
不会倒的鸡蛋2 小时前
网络爬虫详解
前端·chrome·python
码--到成功2 小时前
HTML CSS 基础复习笔记 - 列表使用
css·笔记·html