2025/2/8第一次更新

This commit is contained in:
爱吃咸鱼小猫咪
2025-02-08 18:50:38 +08:00
commit d7af560866
26519 changed files with 5046029 additions and 0 deletions
@@ -0,0 +1,56 @@
"use strict";
const common_vendor = require("../../../../../../common/vendor.js");
if (!Math) {
(TnOverlay + TnIcon)();
}
const TnOverlay = () => "../../overlay/src/overlay.js";
const TnIcon = () => "../../icon/src/icon.js";
const _sfc_main = /* @__PURE__ */ common_vendor.defineComponent({
__name: "popup",
props: common_vendor.popupProps,
emits: common_vendor.popupEmits,
setup(__props) {
const props = __props;
const {
iosDevice,
showOverlay,
showPopup,
visiblePopup,
onClickCloseBtn,
onClickOverlay
} = common_vendor.usePopup(props);
const { ns, overlayZIndex, zIndex, popupContentClass, popupContentStyle } = common_vendor.usePopupCustomStyle(props);
return (_ctx, _cache) => {
return common_vendor.e({
a: !common_vendor.unref(iosDevice) || common_vendor.unref(iosDevice) && common_vendor.unref(visiblePopup)
}, !common_vendor.unref(iosDevice) || common_vendor.unref(iosDevice) && common_vendor.unref(visiblePopup) ? common_vendor.e({
b: common_vendor.o(common_vendor.unref(onClickOverlay)),
c: common_vendor.p({
show: common_vendor.unref(showOverlay),
["z-index"]: common_vendor.unref(overlayZIndex),
opacity: _ctx.overlayOpacity
}),
d: _ctx.closeBtn
}, _ctx.closeBtn ? {
e: common_vendor.p({
name: "close"
}),
f: common_vendor.n(common_vendor.unref(ns).e("close-btn")),
g: common_vendor.n(common_vendor.unref(ns).em("close-btn", _ctx.closeBtnPosition)),
h: common_vendor.o(
//@ts-ignore
(...args) => common_vendor.unref(onClickCloseBtn) && common_vendor.unref(onClickCloseBtn)(...args)
)
} : {}, {
i: common_vendor.n(common_vendor.unref(popupContentClass)),
j: common_vendor.s(common_vendor.unref(popupContentStyle)),
k: common_vendor.n(common_vendor.unref(ns).b()),
l: common_vendor.n(common_vendor.unref(ns).is("show", common_vendor.unref(showPopup))),
m: common_vendor.n(common_vendor.unref(ns).is("visible", common_vendor.unref(visiblePopup))),
n: common_vendor.unref(zIndex)
}) : {});
};
}
});
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__scopeId", "data-v-557a403b"]]);
wx.createComponent(Component);
@@ -0,0 +1,7 @@
{
"component": true,
"usingComponents": {
"tn-overlay": "../../overlay/src/overlay",
"tn-icon": "../../icon/src/icon"
}
}
@@ -0,0 +1 @@
<view wx:if="{{a}}" class="{{['data-v-557a403b', k, l, m, virtualHostClass]}}" style="{{'z-index:' + n + ';' + virtualHostStyle}}"><tn-overlay wx:if="{{c}}" class="data-v-557a403b" virtualHostClass="data-v-557a403b" bindclick="{{b}}" u-i="557a403b-0" bind:__l="__l" u-p="{{c}}"/><view class="{{['data-v-557a403b', i]}}" style="{{j}}"><slot/><view wx:if="{{d}}" class="{{['data-v-557a403b', f, g]}}" catchtap="{{h}}"><block wx:if="{{$slots.closeBtn}}"><slot name="closeBtn"></slot></block><block wx:else><tn-icon wx:if="{{e}}" class="data-v-557a403b" virtualHostClass="data-v-557a403b" u-i="557a403b-1" bind:__l="__l" u-p="{{e}}"/></block></view></view></view>
@@ -0,0 +1,127 @@
/**
* 这里是uni-app内置的常用样式变量
*
* uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量
* 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App
*
*/
/**
* 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能
*
* 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件
*/
/* 颜色变量 */
/* 行为相关颜色 */
/* 文字基本颜色 */
/* 背景颜色 */
/* 边框颜色 */
/* 尺寸变量 */
/* 文字尺寸 */
/* 图片尺寸 */
/* Border Radius */
/* 水平间距 */
/* 垂直间距 */
/* 透明度 */
/* 文章场景相关 */
.tn-popup.data-v-557a403b {
position: fixed;
left: 0;
top: 0;
right: 0;
bottom: 0;
overflow: hidden;
visibility: hidden;
/* 弹出层内容 start */
/* 弹出层内容 end */
/* 关闭按钮 start */
/* 关闭按钮 end */
}
.tn-popup__content.data-v-557a403b {
position: absolute;
opacity: 0;
/* 弹出层位置 start */
/* 弹出层位置 end */
}
.tn-popup__content--center.data-v-557a403b {
left: 50%;
top: 50%;
transform: translate(-50%, -50%) scale(0);
transform-origin: center center;
}
.tn-popup__content--top.data-v-557a403b {
left: 0;
top: 0;
width: 100%;
transform: scaleY(0);
transform-origin: top center;
}
.tn-popup__content--left.data-v-557a403b {
left: 0;
top: 0;
height: 100%;
transform: scaleX(0);
transform-origin: left center;
}
.tn-popup__content--right.data-v-557a403b {
right: 0;
top: 0;
height: 100%;
transform: scaleX(0);
transform-origin: right center;
}
.tn-popup__content--bottom.data-v-557a403b {
left: 0;
bottom: 0;
width: 100%;
transform: scaleY(0);
transform-origin: bottom center;
}
.tn-popup__close-btn.data-v-557a403b {
position: absolute;
padding: 18rpx;
font-size: 32rpx;
line-height: 1;
color: var(--tn-color-gray);
}
.tn-popup__close-btn--right-top.data-v-557a403b {
right: 0rpx;
top: 0rpx;
}
.tn-popup__close-btn--left-top.data-v-557a403b {
left: 0rpx;
top: 0rpx;
}
.tn-popup__close-btn--right-bottom.data-v-557a403b {
right: 0rpx;
bottom: 0rpx;
}
.tn-popup__close-btn--left-bottom.data-v-557a403b {
left: 0rpx;
bottom: 0rpx;
}
.tn-popup.is-show .tn-popup__content.data-v-557a403b {
opacity: 1;
}
.tn-popup.is-show .tn-popup__content--center.data-v-557a403b {
transform: translate(-50%, -50%) scale(1);
}
.tn-popup.is-show .tn-popup__content--top.data-v-557a403b {
transform: scaleY(1);
}
.tn-popup.is-show .tn-popup__content--left.data-v-557a403b {
transform: scaleX(1);
}
.tn-popup.is-show .tn-popup__content--right.data-v-557a403b {
transform: scaleX(1);
}
.tn-popup.is-show .tn-popup__content--bottom.data-v-557a403b {
transform: scaleY(1);
}
.tn-popup.is-visible.data-v-557a403b {
visibility: visible;
}
.tn-popup.is-visible .tn-popup__content.data-v-557a403b {
transition-property: transform, opacity;
transition-duration: 0.3s;
transition-timing-function: ease;
}