uikit 3.15.4-dev.dbc0ede84 → 3.15.5-dev.ec9b624fd
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -0
- package/dist/css/uikit-core-rtl.css +1 -1
- package/dist/css/uikit-core-rtl.min.css +1 -1
- package/dist/css/uikit-core.css +1 -1
- package/dist/css/uikit-core.min.css +1 -1
- package/dist/css/uikit-rtl.css +1 -1
- package/dist/css/uikit-rtl.min.css +1 -1
- package/dist/css/uikit.css +1 -1
- package/dist/css/uikit.min.css +1 -1
- package/dist/js/components/countdown.js +1 -1
- package/dist/js/components/countdown.min.js +1 -1
- package/dist/js/components/filter.js +14 -13
- package/dist/js/components/filter.min.js +1 -1
- package/dist/js/components/lightbox-panel.js +105 -110
- package/dist/js/components/lightbox-panel.min.js +1 -1
- package/dist/js/components/lightbox.js +105 -110
- package/dist/js/components/lightbox.min.js +1 -1
- package/dist/js/components/notification.js +1 -1
- package/dist/js/components/notification.min.js +1 -1
- package/dist/js/components/parallax.js +1 -1
- package/dist/js/components/parallax.min.js +1 -1
- package/dist/js/components/slider-parallax.js +1 -1
- package/dist/js/components/slider-parallax.min.js +1 -1
- package/dist/js/components/slider.js +1 -1
- package/dist/js/components/slider.min.js +1 -1
- package/dist/js/components/slideshow-parallax.js +1 -1
- package/dist/js/components/slideshow-parallax.min.js +1 -1
- package/dist/js/components/slideshow.js +1 -1
- package/dist/js/components/slideshow.min.js +1 -1
- package/dist/js/components/sortable.js +1 -1
- package/dist/js/components/sortable.min.js +1 -1
- package/dist/js/components/tooltip.js +101 -105
- package/dist/js/components/tooltip.min.js +1 -1
- package/dist/js/components/upload.js +1 -1
- package/dist/js/components/upload.min.js +1 -1
- package/dist/js/uikit-core.js +169 -147
- package/dist/js/uikit-core.min.js +2 -2
- package/dist/js/uikit-icons.js +1 -1
- package/dist/js/uikit-icons.min.js +1 -1
- package/dist/js/uikit.js +184 -161
- package/dist/js/uikit.min.js +2 -2
- package/package.json +1 -1
- package/src/js/components/filter.js +14 -12
- package/src/js/core/accordion.js +51 -16
- package/src/js/core/alert.js +19 -21
- package/src/js/mixin/modal.js +28 -29
- package/src/js/mixin/togglable.js +109 -113
- package/tests/accordion.html +1 -1
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "uikit",
|
|
3
3
|
"title": "UIkit",
|
|
4
4
|
"description": "UIkit is a lightweight and modular front-end framework for developing fast and powerful web interfaces.",
|
|
5
|
-
"version": "3.15.
|
|
5
|
+
"version": "3.15.5-dev.ec9b624fd",
|
|
6
6
|
"main": "dist/js/uikit.js",
|
|
7
7
|
"style": "dist/css/uikit.css",
|
|
8
8
|
"sideEffects": [
|
|
@@ -5,6 +5,7 @@ import {
|
|
|
5
5
|
css,
|
|
6
6
|
data,
|
|
7
7
|
each,
|
|
8
|
+
fastdom,
|
|
8
9
|
children as getChildren,
|
|
9
10
|
hasClass,
|
|
10
11
|
includes,
|
|
@@ -42,7 +43,7 @@ export default {
|
|
|
42
43
|
},
|
|
43
44
|
|
|
44
45
|
watch() {
|
|
45
|
-
this
|
|
46
|
+
this.updateState();
|
|
46
47
|
|
|
47
48
|
if (this.selActive !== false) {
|
|
48
49
|
const actives = $$(this.selActive, this.$el);
|
|
@@ -60,7 +61,7 @@ export default {
|
|
|
60
61
|
|
|
61
62
|
watch(list, old) {
|
|
62
63
|
if (old && !isEqualList(list, old)) {
|
|
63
|
-
this
|
|
64
|
+
this.updateState();
|
|
64
65
|
}
|
|
65
66
|
},
|
|
66
67
|
|
|
@@ -68,12 +69,6 @@ export default {
|
|
|
68
69
|
},
|
|
69
70
|
},
|
|
70
71
|
|
|
71
|
-
update: {
|
|
72
|
-
write() {
|
|
73
|
-
this.setState(this.getState(), false);
|
|
74
|
-
},
|
|
75
|
-
},
|
|
76
|
-
|
|
77
72
|
events: [
|
|
78
73
|
{
|
|
79
74
|
name: 'click',
|
|
@@ -113,19 +108,26 @@ export default {
|
|
|
113
108
|
|
|
114
109
|
trigger(this.$el, 'beforeFilter', [this, state]);
|
|
115
110
|
|
|
116
|
-
|
|
117
|
-
toggleClass(el, this.cls, !!matchFilter(el, this.attrItem, state))
|
|
118
|
-
|
|
111
|
+
this.toggles.forEach((el) =>
|
|
112
|
+
toggleClass(el, this.cls, !!matchFilter(el, this.attrItem, state))
|
|
113
|
+
);
|
|
119
114
|
|
|
120
115
|
await Promise.all(
|
|
121
116
|
$$(this.target, this.$el).map((target) => {
|
|
122
|
-
const filterFn = () =>
|
|
117
|
+
const filterFn = () => {
|
|
118
|
+
applyState(state, target, getChildren(target));
|
|
119
|
+
this.$update(this.$el);
|
|
120
|
+
};
|
|
123
121
|
return animate ? this.animate(filterFn, target) : filterFn();
|
|
124
122
|
})
|
|
125
123
|
);
|
|
126
124
|
|
|
127
125
|
trigger(this.$el, 'afterFilter', [this]);
|
|
128
126
|
},
|
|
127
|
+
|
|
128
|
+
updateState() {
|
|
129
|
+
fastdom.write(() => this.setState(this.getState(), false));
|
|
130
|
+
},
|
|
129
131
|
},
|
|
130
132
|
};
|
|
131
133
|
|
package/src/js/core/accordion.js
CHANGED
|
@@ -1,19 +1,25 @@
|
|
|
1
1
|
import Class from '../mixin/class';
|
|
2
2
|
import Lazyload from '../mixin/lazyload';
|
|
3
|
-
import
|
|
3
|
+
import Togglable from '../mixin/togglable';
|
|
4
4
|
import {
|
|
5
5
|
$,
|
|
6
6
|
$$,
|
|
7
7
|
attr,
|
|
8
|
+
css,
|
|
8
9
|
filter,
|
|
9
10
|
getIndex,
|
|
10
11
|
hasClass,
|
|
11
12
|
includes,
|
|
12
13
|
index,
|
|
13
14
|
isInView,
|
|
15
|
+
noop,
|
|
14
16
|
scrollIntoView,
|
|
17
|
+
toFloat,
|
|
15
18
|
toggleClass,
|
|
19
|
+
Transition,
|
|
20
|
+
unwrap,
|
|
16
21
|
within,
|
|
22
|
+
wrapAll,
|
|
17
23
|
} from 'uikit-util';
|
|
18
24
|
|
|
19
25
|
export default {
|
|
@@ -127,28 +133,25 @@ export default {
|
|
|
127
133
|
}
|
|
128
134
|
|
|
129
135
|
for (const el of items) {
|
|
130
|
-
this.toggleElement(el, !hasClass(el, this.clsOpen),
|
|
136
|
+
this.toggleElement(el, !hasClass(el, this.clsOpen), (el, show) => {
|
|
131
137
|
toggleClass(el, this.clsOpen, show);
|
|
132
138
|
attr($(this.$props.toggle, el), 'aria-expanded', show);
|
|
133
139
|
|
|
134
|
-
const content = $(this.content, el);
|
|
135
|
-
|
|
136
140
|
if (animate === false || !this.animation) {
|
|
137
|
-
content
|
|
138
|
-
hide(content, !show);
|
|
141
|
+
hide($(this.content, el), !show);
|
|
139
142
|
return;
|
|
140
143
|
}
|
|
141
144
|
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
}
|
|
150
|
-
}
|
|
151
|
-
}
|
|
145
|
+
return transition(el, show, this).then(() => {
|
|
146
|
+
if (show) {
|
|
147
|
+
const toggle = $(this.$props.toggle, el);
|
|
148
|
+
requestAnimationFrame(() => {
|
|
149
|
+
if (!isInView(toggle)) {
|
|
150
|
+
scrollIntoView(toggle, { offset: this.offset });
|
|
151
|
+
}
|
|
152
|
+
});
|
|
153
|
+
}
|
|
154
|
+
}, noop);
|
|
152
155
|
});
|
|
153
156
|
}
|
|
154
157
|
},
|
|
@@ -158,3 +161,35 @@ export default {
|
|
|
158
161
|
function hide(el, hide) {
|
|
159
162
|
el && (el.hidden = hide);
|
|
160
163
|
}
|
|
164
|
+
|
|
165
|
+
async function transition(el, show, { content, duration, velocity, transition }) {
|
|
166
|
+
content = el._wrapper?.firstElementChild || $(content, el);
|
|
167
|
+
|
|
168
|
+
if (!el._wrapper) {
|
|
169
|
+
el._wrapper = wrapAll(content, '<div>');
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
const wrapper = el._wrapper;
|
|
173
|
+
css(wrapper, 'overflow', 'hidden');
|
|
174
|
+
const currentHeight = toFloat(css(wrapper, 'height'));
|
|
175
|
+
|
|
176
|
+
await Transition.cancel(wrapper);
|
|
177
|
+
hide(content, false);
|
|
178
|
+
|
|
179
|
+
const endHeight =
|
|
180
|
+
toFloat(css(content, 'height')) +
|
|
181
|
+
toFloat(css(content, 'marginTop')) +
|
|
182
|
+
toFloat(css(content, 'marginBottom'));
|
|
183
|
+
const percent = currentHeight / endHeight;
|
|
184
|
+
duration = (velocity * endHeight + duration) * (show ? 1 - percent : percent);
|
|
185
|
+
css(wrapper, 'height', currentHeight);
|
|
186
|
+
|
|
187
|
+
await Transition.start(wrapper, { height: show ? endHeight : 0 }, duration, transition);
|
|
188
|
+
|
|
189
|
+
unwrap(content);
|
|
190
|
+
delete el._wrapper;
|
|
191
|
+
|
|
192
|
+
if (!show) {
|
|
193
|
+
hide(content, true);
|
|
194
|
+
}
|
|
195
|
+
}
|
package/src/js/core/alert.js
CHANGED
|
@@ -33,30 +33,28 @@ export default {
|
|
|
33
33
|
|
|
34
34
|
methods: {
|
|
35
35
|
async close() {
|
|
36
|
-
await this.toggleElement(this.$el, false, animate
|
|
36
|
+
await this.toggleElement(this.$el, false, animate);
|
|
37
37
|
this.$destroy(true);
|
|
38
38
|
},
|
|
39
39
|
},
|
|
40
40
|
};
|
|
41
41
|
|
|
42
|
-
function animate({ duration, transition, velocity }) {
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
);
|
|
61
|
-
};
|
|
42
|
+
function animate(el, show, { duration, transition, velocity }) {
|
|
43
|
+
const height = toFloat(css(el, 'height'));
|
|
44
|
+
css(el, 'height', height);
|
|
45
|
+
return Transition.start(
|
|
46
|
+
el,
|
|
47
|
+
{
|
|
48
|
+
height: 0,
|
|
49
|
+
marginTop: 0,
|
|
50
|
+
marginBottom: 0,
|
|
51
|
+
paddingTop: 0,
|
|
52
|
+
paddingBottom: 0,
|
|
53
|
+
borderTop: 0,
|
|
54
|
+
borderBottom: 0,
|
|
55
|
+
opacity: 0,
|
|
56
|
+
},
|
|
57
|
+
velocity * height + duration,
|
|
58
|
+
transition
|
|
59
|
+
);
|
|
62
60
|
}
|
package/src/js/mixin/modal.js
CHANGED
|
@@ -240,42 +240,41 @@ export default {
|
|
|
240
240
|
);
|
|
241
241
|
}
|
|
242
242
|
|
|
243
|
-
return this.toggleElement(this.$el, true, animate
|
|
243
|
+
return this.toggleElement(this.$el, true, animate);
|
|
244
244
|
},
|
|
245
245
|
|
|
246
246
|
hide() {
|
|
247
|
-
return this.toggleElement(this.$el, false, animate
|
|
247
|
+
return this.toggleElement(this.$el, false, animate);
|
|
248
248
|
},
|
|
249
249
|
},
|
|
250
250
|
};
|
|
251
251
|
|
|
252
|
-
function animate({ transitionElement, _toggle }) {
|
|
253
|
-
return (
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
(
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
).then(() => delete el._reject);
|
|
252
|
+
function animate(el, show, { transitionElement, _toggle }) {
|
|
253
|
+
return new Promise((resolve, reject) =>
|
|
254
|
+
once(el, 'show hide', () => {
|
|
255
|
+
el._reject?.();
|
|
256
|
+
el._reject = reject;
|
|
257
|
+
|
|
258
|
+
_toggle(el, show);
|
|
259
|
+
|
|
260
|
+
const off = once(
|
|
261
|
+
transitionElement,
|
|
262
|
+
'transitionstart',
|
|
263
|
+
() => {
|
|
264
|
+
once(transitionElement, 'transitionend transitioncancel', resolve, {
|
|
265
|
+
self: true,
|
|
266
|
+
});
|
|
267
|
+
clearTimeout(timer);
|
|
268
|
+
},
|
|
269
|
+
{ self: true }
|
|
270
|
+
);
|
|
271
|
+
|
|
272
|
+
const timer = setTimeout(() => {
|
|
273
|
+
off();
|
|
274
|
+
resolve();
|
|
275
|
+
}, toMs(css(transitionElement, 'transitionDuration')));
|
|
276
|
+
})
|
|
277
|
+
).then(() => delete el._reject);
|
|
279
278
|
}
|
|
280
279
|
|
|
281
280
|
function toMs(time) {
|
|
@@ -67,11 +67,11 @@ export default {
|
|
|
67
67
|
isFunction(animate)
|
|
68
68
|
? animate
|
|
69
69
|
: animate === false || !this.hasAnimation
|
|
70
|
-
? toggleInstant
|
|
70
|
+
? toggleInstant
|
|
71
71
|
: this.hasTransition
|
|
72
|
-
? toggleTransition
|
|
73
|
-
: toggleAnimation
|
|
74
|
-
)(el, show);
|
|
72
|
+
? toggleTransition
|
|
73
|
+
: toggleAnimation
|
|
74
|
+
)(el, show, this);
|
|
75
75
|
|
|
76
76
|
const cls = show ? this.clsEnter : this.clsLeave;
|
|
77
77
|
|
|
@@ -131,16 +131,18 @@ export default {
|
|
|
131
131
|
},
|
|
132
132
|
};
|
|
133
133
|
|
|
134
|
-
function toggleInstant({ _toggle }) {
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
return _toggle(el, show);
|
|
139
|
-
};
|
|
134
|
+
function toggleInstant(el, show, { _toggle }) {
|
|
135
|
+
Animation.cancel(el);
|
|
136
|
+
Transition.cancel(el);
|
|
137
|
+
return _toggle(el, show);
|
|
140
138
|
}
|
|
141
139
|
|
|
142
|
-
export function toggleTransition(
|
|
143
|
-
|
|
140
|
+
export async function toggleTransition(
|
|
141
|
+
el,
|
|
142
|
+
show,
|
|
143
|
+
{ animation, duration, velocity, transition, _toggle }
|
|
144
|
+
) {
|
|
145
|
+
const [mode = 'reveal', startProp = 'top'] = animation[0]?.split('-') || [];
|
|
144
146
|
|
|
145
147
|
const dirs = [
|
|
146
148
|
['left', 'right'],
|
|
@@ -153,111 +155,105 @@ export function toggleTransition(cmp) {
|
|
|
153
155
|
const marginProp = `margin-${dir[0]}`;
|
|
154
156
|
const marginStartProp = `margin-${startProp}`;
|
|
155
157
|
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
158
|
+
let currentDim = dimensions(el)[dimProp];
|
|
159
|
+
|
|
160
|
+
const inProgress = Transition.inProgress(el);
|
|
161
|
+
await Transition.cancel(el);
|
|
162
|
+
|
|
163
|
+
if (show) {
|
|
164
|
+
_toggle(el, true);
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
const prevProps = Object.fromEntries(
|
|
168
|
+
[
|
|
169
|
+
'padding',
|
|
170
|
+
'border',
|
|
171
|
+
'width',
|
|
172
|
+
'height',
|
|
173
|
+
'minWidth',
|
|
174
|
+
'minHeight',
|
|
175
|
+
'overflowY',
|
|
176
|
+
'overflowX',
|
|
177
|
+
marginProp,
|
|
178
|
+
marginStartProp,
|
|
179
|
+
].map((key) => [key, el.style[key]])
|
|
180
|
+
);
|
|
181
|
+
|
|
182
|
+
const dim = dimensions(el);
|
|
183
|
+
const currentMargin = toFloat(css(el, marginProp));
|
|
184
|
+
const marginStart = toFloat(css(el, marginStartProp));
|
|
185
|
+
const endDim = dim[dimProp] + marginStart;
|
|
186
|
+
|
|
187
|
+
if (!inProgress && !show) {
|
|
188
|
+
currentDim += marginStart;
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
const [wrapper] = wrapInner(el, '<div>');
|
|
192
|
+
css(wrapper, {
|
|
193
|
+
boxSizing: 'border-box',
|
|
194
|
+
height: dim.height,
|
|
195
|
+
width: dim.width,
|
|
196
|
+
...css(el, [
|
|
197
|
+
'overflow',
|
|
198
|
+
'padding',
|
|
199
|
+
'borderTop',
|
|
200
|
+
'borderRight',
|
|
201
|
+
'borderBottom',
|
|
202
|
+
'borderLeft',
|
|
203
|
+
'borderImage',
|
|
204
|
+
marginStartProp,
|
|
205
|
+
]),
|
|
206
|
+
});
|
|
207
|
+
|
|
208
|
+
css(el, {
|
|
209
|
+
padding: 0,
|
|
210
|
+
border: 0,
|
|
211
|
+
minWidth: 0,
|
|
212
|
+
minHeight: 0,
|
|
213
|
+
[marginStartProp]: 0,
|
|
214
|
+
width: dim.width,
|
|
215
|
+
height: dim.height,
|
|
216
|
+
overflow: 'hidden',
|
|
217
|
+
[dimProp]: currentDim,
|
|
218
|
+
});
|
|
219
|
+
|
|
220
|
+
const percent = currentDim / endDim;
|
|
221
|
+
duration = (velocity * endDim + duration) * (show ? 1 - percent : percent);
|
|
222
|
+
const endProps = { [dimProp]: show ? endDim : 0 };
|
|
223
|
+
|
|
224
|
+
if (end) {
|
|
225
|
+
css(el, marginProp, endDim - currentDim + currentMargin);
|
|
226
|
+
endProps[marginProp] = show ? currentMargin : endDim + currentMargin;
|
|
227
|
+
}
|
|
228
|
+
|
|
229
|
+
if (!end ^ (mode === 'reveal')) {
|
|
230
|
+
css(wrapper, marginProp, -endDim + currentDim);
|
|
231
|
+
Transition.start(wrapper, { [marginProp]: show ? 0 : -endDim }, duration, transition);
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
try {
|
|
235
|
+
await Transition.start(el, endProps, duration, transition);
|
|
236
|
+
} finally {
|
|
237
|
+
css(el, prevProps);
|
|
238
|
+
unwrap(wrapper.firstChild);
|
|
239
|
+
|
|
240
|
+
if (!show) {
|
|
241
|
+
_toggle(el, false);
|
|
228
242
|
}
|
|
229
|
-
|
|
230
|
-
if (!end ^ (mode === 'reveal')) {
|
|
231
|
-
css(wrapper, marginProp, -endDim + currentDim);
|
|
232
|
-
Transition.start(wrapper, { [marginProp]: show ? 0 : -endDim }, duration, transition);
|
|
233
|
-
}
|
|
234
|
-
|
|
235
|
-
try {
|
|
236
|
-
await Transition.start(el, endProps, duration, transition);
|
|
237
|
-
} finally {
|
|
238
|
-
css(el, prevProps);
|
|
239
|
-
unwrap(wrapper.firstChild);
|
|
240
|
-
|
|
241
|
-
if (!show) {
|
|
242
|
-
_toggle(el, false);
|
|
243
|
-
}
|
|
244
|
-
}
|
|
245
|
-
};
|
|
243
|
+
}
|
|
246
244
|
}
|
|
247
245
|
|
|
248
|
-
function toggleAnimation(cmp) {
|
|
249
|
-
|
|
250
|
-
Animation.cancel(el);
|
|
246
|
+
function toggleAnimation(el, show, cmp) {
|
|
247
|
+
Animation.cancel(el);
|
|
251
248
|
|
|
252
|
-
|
|
249
|
+
const { animation, duration, _toggle } = cmp;
|
|
253
250
|
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
251
|
+
if (show) {
|
|
252
|
+
_toggle(el, true);
|
|
253
|
+
return Animation.in(el, animation[0], duration, cmp.origin);
|
|
254
|
+
}
|
|
258
255
|
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
};
|
|
256
|
+
return Animation.out(el, animation[1] || animation[0], duration, cmp.origin).then(() =>
|
|
257
|
+
_toggle(el, false)
|
|
258
|
+
);
|
|
263
259
|
}
|
package/tests/accordion.html
CHANGED
|
@@ -191,7 +191,7 @@
|
|
|
191
191
|
<td><code>animation</code></td>
|
|
192
192
|
<td>Boolean</td>
|
|
193
193
|
<td>true</td>
|
|
194
|
-
<td>
|
|
194
|
+
<td>Reveal item directly or with a transition. </td>
|
|
195
195
|
</tr>
|
|
196
196
|
<tr>
|
|
197
197
|
<td><code>duration</code></td>
|