@1337exp/taoui 4.0.0 → 4.0.1
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 +4 -0
- package/dist/index.cjs +3 -33
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +4 -34
- package/dist/index.mjs.map +1 -1
- package/dist/styles.css +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 4.0.1
|
|
4
|
+
|
|
5
|
+
- **TaoScrollTop:** the ripple is gone. It painted the wave in a tint that disappeared on the accent fill, so it was practically invisible and cost a DOM node, a timer and an `overflow: hidden` clip. The button now has the same 1px press as `TaoButton`.
|
|
6
|
+
|
|
3
7
|
## 4.0.0
|
|
4
8
|
|
|
5
9
|
### Breaking: English is the default language
|
package/dist/index.cjs
CHANGED
|
@@ -3834,11 +3834,10 @@
|
|
|
3834
3834
|
const _hoisted_1$w = ["tabindex", "aria-label"];
|
|
3835
3835
|
const _hoisted_2$t = { class: "tao-scroll-top__content" };
|
|
3836
3836
|
const _hoisted_3$p = {
|
|
3837
|
-
key:
|
|
3837
|
+
key: 0,
|
|
3838
3838
|
class: "tao-scroll-top__text",
|
|
3839
3839
|
"aria-hidden": "true"
|
|
3840
3840
|
};
|
|
3841
|
-
const RIPPLE_DURATION = 750;
|
|
3842
3841
|
const _sfc_main$y = /* @__PURE__ */ vue.defineComponent({
|
|
3843
3842
|
...{ name: "TaoScrollTop", inheritAttrs: false },
|
|
3844
3843
|
__name: "TaoScrollTop",
|
|
@@ -3877,14 +3876,7 @@
|
|
|
3877
3876
|
const captionSide = vue.computed(() => props.labelSide ?? (props.side === "right" ? "left" : "right"));
|
|
3878
3877
|
const caption = vue.computed(() => props.label ?? (isText.value ? l10n.value.ariaLabel : void 0));
|
|
3879
3878
|
const accessibleName = vue.computed(() => props.ariaLabel || props.label || l10n.value.ariaLabel);
|
|
3880
|
-
const rippleStyle = vue.reactive({
|
|
3881
|
-
top: fmtProp(-1 * props.size),
|
|
3882
|
-
left: fmtProp(-1 * props.size),
|
|
3883
|
-
width: "200%",
|
|
3884
|
-
height: "200%"
|
|
3885
|
-
});
|
|
3886
3879
|
const isActive = vue.ref(false);
|
|
3887
|
-
const isRippleActive = vue.ref(false);
|
|
3888
3880
|
function getScrollValue() {
|
|
3889
3881
|
if (typeof window.pageYOffset !== "undefined") {
|
|
3890
3882
|
return window.pageYOffset;
|
|
@@ -3918,23 +3910,6 @@
|
|
|
3918
3910
|
prevPos = pY;
|
|
3919
3911
|
isActive.value = tooFar && activeBack;
|
|
3920
3912
|
}
|
|
3921
|
-
function onClick(e) {
|
|
3922
|
-
if (!isText.value && !isRippleActive.value) {
|
|
3923
|
-
const elTarget = e.currentTarget;
|
|
3924
|
-
if (elTarget) {
|
|
3925
|
-
const rect = elTarget.getBoundingClientRect();
|
|
3926
|
-
const top = e.clientY - rect.top;
|
|
3927
|
-
const left = e.clientX - rect.left;
|
|
3928
|
-
rippleStyle.top = fmtProp(top - props.size);
|
|
3929
|
-
rippleStyle.left = fmtProp(left - props.size);
|
|
3930
|
-
}
|
|
3931
|
-
isRippleActive.value = true;
|
|
3932
|
-
setTimeout(() => {
|
|
3933
|
-
isRippleActive.value = false;
|
|
3934
|
-
}, RIPPLE_DURATION);
|
|
3935
|
-
}
|
|
3936
|
-
goToTop();
|
|
3937
|
-
}
|
|
3938
3913
|
vue.onBeforeMount(() => {
|
|
3939
3914
|
window.addEventListener("scroll", onScroll);
|
|
3940
3915
|
});
|
|
@@ -3963,14 +3938,9 @@
|
|
|
3963
3938
|
isText.value && `tao-scroll-top--caption-${captionSide.value}`
|
|
3964
3939
|
]],
|
|
3965
3940
|
"aria-label": accessibleName.value,
|
|
3966
|
-
onClick: vue.withModifiers(
|
|
3941
|
+
onClick: vue.withModifiers(goToTop, ["prevent"])
|
|
3967
3942
|
}), [
|
|
3968
3943
|
vue.createElementVNode("span", _hoisted_2$t, [
|
|
3969
|
-
!isText.value ? (vue.openBlock(), vue.createElementBlock("span", {
|
|
3970
|
-
key: 0,
|
|
3971
|
-
class: vue.normalizeClass([{ "tao-scroll-top__ripple--active": isRippleActive.value }, "tao-scroll-top__ripple"]),
|
|
3972
|
-
style: vue.normalizeStyle(rippleStyle)
|
|
3973
|
-
}, null, 6)) : vue.createCommentVNode("", true),
|
|
3974
3944
|
isText.value && caption.value ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_3$p, vue.toDisplayString(caption.value), 1)) : vue.createCommentVNode("", true),
|
|
3975
3945
|
vue.renderSlot(_ctx.$slots, "default", {}, () => [
|
|
3976
3946
|
_cache[0] || (_cache[0] = vue.createElementVNode("svg", {
|
|
@@ -3997,7 +3967,7 @@
|
|
|
3997
3967
|
};
|
|
3998
3968
|
}
|
|
3999
3969
|
});
|
|
4000
|
-
const TaoScrollTop = /* @__PURE__ */ _export_sfc(_sfc_main$y, [["__scopeId", "data-v-
|
|
3970
|
+
const TaoScrollTop = /* @__PURE__ */ _export_sfc(_sfc_main$y, [["__scopeId", "data-v-7bcb0179"]]);
|
|
4001
3971
|
const _hoisted_1$v = { class: "tao-progress" };
|
|
4002
3972
|
const _hoisted_2$s = {
|
|
4003
3973
|
key: 0,
|