Skip to content

Commit 5ae0d1e

Browse files
committed
fix lint
1 parent 835472f commit 5ae0d1e

File tree

3 files changed

+86
-86
lines changed

3 files changed

+86
-86
lines changed

src/components/child-components/vuescroll-panel.js

Lines changed: 74 additions & 74 deletions
Original file line numberDiff line numberDiff line change
@@ -176,84 +176,84 @@ function createTipDom(h, vm, type) {
176176
return dom[0];
177177
}
178178
switch (stage) {
179-
case 'deactive':
180-
dom = (
181-
<svg
182-
version="1.1"
183-
xmlns="http://www.w3.org/2000/svg"
184-
xmlnsXlink="http://www.w3.org/1999/xlink"
185-
x="0px"
186-
y="0px"
187-
viewBox="0 0 1000 1000"
188-
enable-background="new 0 0 1000 1000"
189-
xmlSpace="preserve"
190-
>
191-
<metadata> Svg Vector Icons : http://www.sfont.cn </metadata>
192-
<g>
193-
<g transform="matrix(1 0 0 -1 0 1008)">
194-
<path d="M10,543l490,455l490-455L885,438L570,735.5V18H430v717.5L115,438L10,543z" />
195-
</g>
179+
case 'deactive':
180+
dom = (
181+
<svg
182+
version="1.1"
183+
xmlns="http://www.w3.org/2000/svg"
184+
xmlnsXlink="http://www.w3.org/1999/xlink"
185+
x="0px"
186+
y="0px"
187+
viewBox="0 0 1000 1000"
188+
enable-background="new 0 0 1000 1000"
189+
xmlSpace="preserve"
190+
>
191+
<metadata> Svg Vector Icons : http://www.sfont.cn </metadata>
192+
<g>
193+
<g transform="matrix(1 0 0 -1 0 1008)">
194+
<path d="M10,543l490,455l490-455L885,438L570,735.5V18H430v717.5L115,438L10,543z" />
196195
</g>
197-
</svg>
198-
);
199-
break;
200-
case 'start':
201-
// IE seems not supporting animateTransform
202-
/* istanbul ignore if */
203-
if (isIE()) {
204-
dom = null;
205-
break;
206-
}
207-
dom = (
208-
<svg
209-
version="1.1"
210-
id="loader-1"
211-
xmlns="http://www.w3.org/2000/svg"
212-
xmlnsXlink="http://www.w3.org/1999/xlink"
213-
x="0px"
214-
y="0px"
215-
viewBox="0 0 50 50"
216-
style="enable-background:new 0 0 50 50;"
217-
xmlSpace="preserve"
218-
>
219-
<path
220-
fill="#000"
221-
d="M43.935,25.145c0-10.318-8.364-18.683-18.683-18.683c-10.318,0-18.683,8.365-18.683,18.683h4.068c0-8.071,6.543-14.615,14.615-14.615c8.072,0,14.615,6.543,14.615,14.615H43.935z"
222-
>
223-
<animateTransform
224-
attributeType="xml"
225-
attributeName="transform"
226-
type="rotate"
227-
from="0 25 25"
228-
to="360 25 25"
229-
dur="0.6s"
230-
repeatCount="indefinite"
231-
/>
232-
</path>
233-
</svg>
234-
);
196+
</g>
197+
</svg>
198+
);
199+
break;
200+
case 'start':
201+
// IE seems not supporting animateTransform
202+
/* istanbul ignore if */
203+
if (isIE()) {
204+
dom = null;
235205
break;
236-
case 'active':
237-
dom = (
238-
<svg
239-
version="1.1"
240-
xmlns="http://www.w3.org/2000/svg"
241-
xmlnsXlink="http://www.w3.org/1999/xlink"
242-
x="0px"
243-
y="0px"
244-
viewBox="0 0 1000 1000"
245-
enable-background="new 0 0 1000 1000"
246-
xmlSpace="preserve"
206+
}
207+
dom = (
208+
<svg
209+
version="1.1"
210+
id="loader-1"
211+
xmlns="http://www.w3.org/2000/svg"
212+
xmlnsXlink="http://www.w3.org/1999/xlink"
213+
x="0px"
214+
y="0px"
215+
viewBox="0 0 50 50"
216+
style="enable-background:new 0 0 50 50;"
217+
xmlSpace="preserve"
218+
>
219+
<path
220+
fill="#000"
221+
d="M43.935,25.145c0-10.318-8.364-18.683-18.683-18.683c-10.318,0-18.683,8.365-18.683,18.683h4.068c0-8.071,6.543-14.615,14.615-14.615c8.072,0,14.615,6.543,14.615,14.615H43.935z"
247222
>
248-
<metadata> Svg Vector Icons : http://www.sfont.cn </metadata>
249-
<g>
250-
<g transform="matrix(1 0 0 -1 0 1008)">
251-
<path d="M500,18L10,473l105,105l315-297.5V998h140V280.5L885,578l105-105L500,18z" />
252-
</g>
223+
<animateTransform
224+
attributeType="xml"
225+
attributeName="transform"
226+
type="rotate"
227+
from="0 25 25"
228+
to="360 25 25"
229+
dur="0.6s"
230+
repeatCount="indefinite"
231+
/>
232+
</path>
233+
</svg>
234+
);
235+
break;
236+
case 'active':
237+
dom = (
238+
<svg
239+
version="1.1"
240+
xmlns="http://www.w3.org/2000/svg"
241+
xmlnsXlink="http://www.w3.org/1999/xlink"
242+
x="0px"
243+
y="0px"
244+
viewBox="0 0 1000 1000"
245+
enable-background="new 0 0 1000 1000"
246+
xmlSpace="preserve"
247+
>
248+
<metadata> Svg Vector Icons : http://www.sfont.cn </metadata>
249+
<g>
250+
<g transform="matrix(1 0 0 -1 0 1008)">
251+
<path d="M500,18L10,473l105,105l315-297.5V998h140V280.5L885,578l105-105L500,18z" />
253252
</g>
254-
</svg>
255-
);
256-
break;
253+
</g>
254+
</svg>
255+
);
256+
break;
257257
}
258258
return dom;
259259
}

src/components/vuescroll.js

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -18,16 +18,16 @@ import {
1818
function findValuesByMode(mode, vm) {
1919
let axis = {};
2020
switch (mode) {
21-
case 'native':
22-
case 'pure-native':
23-
axis = {
24-
x: vm.scrollPanelElm.scrollLeft,
25-
y: vm.scrollPanelElm.scrollTop
26-
};
27-
break;
28-
case 'slide':
29-
axis = { x: vm.scroller.__scrollLeft, y: vm.scroller.__scrollTop };
30-
break;
21+
case 'native':
22+
case 'pure-native':
23+
axis = {
24+
x: vm.scrollPanelElm.scrollLeft,
25+
y: vm.scrollPanelElm.scrollTop
26+
};
27+
break;
28+
case 'slide':
29+
axis = { x: vm.scroller.__scrollLeft, y: vm.scroller.__scrollTop };
30+
break;
3131
}
3232
return axis;
3333
}

test/unit/specs/slot.spec.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ describe('test-slot', () => {
1818
destroyVM(vm);
1919
});
2020

21-
it("contaner's dataset id should be container", done => {
21+
it('contaner\'s dataset id should be container', done => {
2222
vm = createVue(
2323
{
2424
template: makeTemplate(
@@ -53,7 +53,7 @@ describe('test-slot', () => {
5353
});
5454
});
5555

56-
it("scroll-panel's dataset id should be panel", done => {
56+
it('scroll-panel\'s dataset id should be panel', done => {
5757
vm = createVue(
5858
{
5959
template: makeTemplate(

0 commit comments

Comments
 (0)