Commit 0862174d authored by baiyaaaaa's avatar baiyaaaaa Committed by GitHub

Merge pull request #1898 from hisland/dev

layout: all in right, clear float fixed #1893
parents 775d5c16 15a44bf9
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
white-space: nowrap; white-space: nowrap;
padding: 2px 5px; padding: 2px 5px;
color: var(--pagination-color); color: var(--pagination-color);
@utils-clearfix;
span, span,
button { button {
......
...@@ -40,6 +40,18 @@ describe('Pagination', () => { ...@@ -40,6 +40,18 @@ describe('Pagination', () => {
expect(elm.querySelector('.el-pagination__total')).to.not.exist; expect(elm.querySelector('.el-pagination__total')).to.not.exist;
}); });
it('layout: all in right, need clear float', () => {
vm = createTest(Pagination, {
layout: '->, prev, pager, next',
total: 100
}, true);
const elm = vm.$el;
let right_div = elm.querySelector('.el-pagination__rightwrapper');
expect(elm.clientHeight > 0 && right_div.clientHeight > 0).to.equal(true);
// elm 将来 padding 可能会变化, 所以使用 >= 来判定
expect(elm.clientHeight >= right_div.clientHeight).to.equal(true);
});
it('custom slot', () => { it('custom slot', () => {
vm = createVue({ vm = createVue({
template: ` template: `
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment