弹窗
This commit is contained in:
103
unpackage/dist/dev/mp-weixin/NewAddedPk.js
vendored
Normal file
103
unpackage/dist/dev/mp-weixin/NewAddedPk.js
vendored
Normal file
@@ -0,0 +1,103 @@
|
||||
"use strict";
|
||||
const common_vendor = require("./common/vendor.js");
|
||||
const components_NationalDictionary = require("./components/NationalDictionary.js");
|
||||
const common_assets = require("./common/assets.js");
|
||||
const _sfc_main = {
|
||||
data() {
|
||||
return {
|
||||
gender: "",
|
||||
Gender: ["男", "女"],
|
||||
Country: components_NationalDictionary.countryNamesArray,
|
||||
country: "",
|
||||
nameAnchor: "",
|
||||
numberCoins: "",
|
||||
remarks: "",
|
||||
Display: false,
|
||||
options: [
|
||||
{ label: "选项一", value: "1" },
|
||||
{ label: "选项二", value: "2" },
|
||||
{ label: "选项三", value: "3" }
|
||||
]
|
||||
};
|
||||
},
|
||||
onLoad() {
|
||||
common_vendor.index.getStorage({
|
||||
key: "userinfo",
|
||||
success: (res) => {
|
||||
}
|
||||
});
|
||||
},
|
||||
methods: {
|
||||
handleOverlayClick(event) {
|
||||
if (event.target === this.$el) {
|
||||
this.Display = false;
|
||||
}
|
||||
},
|
||||
open() {
|
||||
if (this.Display) {
|
||||
this.Display = false;
|
||||
} else {
|
||||
this.Display = true;
|
||||
}
|
||||
},
|
||||
//获取主播名称
|
||||
NameAnchor: function(event) {
|
||||
this.nameAnchor = event.target.value;
|
||||
},
|
||||
Publish() {
|
||||
common_vendor.index.__f__("log", "at pages/NewAddedPk/NewAddedPk.vue:103", this.nameAnchor, this.gender, this.country, this.numberCoins, this.remarks);
|
||||
}
|
||||
}
|
||||
};
|
||||
if (!Array) {
|
||||
const _easycom_uni_combox2 = common_vendor.resolveComponent("uni-combox");
|
||||
const _easycom_wht_select2 = common_vendor.resolveComponent("wht-select");
|
||||
const _easycom_uni_number_box2 = common_vendor.resolveComponent("uni-number-box");
|
||||
const _easycom_uni_easyinput2 = common_vendor.resolveComponent("uni-easyinput");
|
||||
(_easycom_uni_combox2 + _easycom_wht_select2 + _easycom_uni_number_box2 + _easycom_uni_easyinput2)();
|
||||
}
|
||||
const _easycom_uni_combox = () => "./uni_modules/uni-combox/components/uni-combox/uni-combox.js";
|
||||
const _easycom_wht_select = () => "./uni_modules/wht-select/components/wht-select/wht-select.js";
|
||||
const _easycom_uni_number_box = () => "./uni_modules/uni-number-box/components/uni-number-box/uni-number-box.js";
|
||||
const _easycom_uni_easyinput = () => "./uni_modules/uni-easyinput/components/uni-easyinput/uni-easyinput.js";
|
||||
if (!Math) {
|
||||
(_easycom_uni_combox + _easycom_wht_select + _easycom_uni_number_box + _easycom_uni_easyinput)();
|
||||
}
|
||||
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
||||
return common_vendor.e({
|
||||
a: $data.Display
|
||||
}, $data.Display ? {
|
||||
b: common_vendor.o$1(($event) => $options.open()),
|
||||
c: common_assets._imports_0$5,
|
||||
d: common_vendor.o$1((...args) => $options.NameAnchor && $options.NameAnchor(...args)),
|
||||
e: common_vendor.o$1(($event) => $data.gender = $event),
|
||||
f: common_vendor.p({
|
||||
candidates: $data.Gender,
|
||||
placeholder: "请选择性别",
|
||||
modelValue: $data.gender
|
||||
}),
|
||||
g: common_vendor.o$1(($event) => $data.country = $event),
|
||||
h: common_vendor.p({
|
||||
options: $data.options,
|
||||
placeholder: "请选择国家",
|
||||
modelValue: $data.country
|
||||
}),
|
||||
i: common_vendor.o$1(($event) => $data.numberCoins = $event),
|
||||
j: common_vendor.p({
|
||||
modelValue: $data.numberCoins
|
||||
}),
|
||||
k: common_vendor.o$1(($event) => $data.remarks = $event),
|
||||
l: common_vendor.p({
|
||||
type: "textarea",
|
||||
placeholder: "备注",
|
||||
modelValue: $data.remarks
|
||||
}),
|
||||
m: common_vendor.o$1(($event) => $options.Publish()),
|
||||
n: common_vendor.o$1(() => {
|
||||
}),
|
||||
o: common_vendor.o$1(($event) => $options.open())
|
||||
} : {});
|
||||
}
|
||||
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-96d38e2b"]]);
|
||||
exports.MiniProgramPage = MiniProgramPage;
|
||||
//# sourceMappingURL=../.sourcemap/mp-weixin/NewAddedPk.js.map
|
||||
1
unpackage/dist/dev/mp-weixin/app.js
vendored
1
unpackage/dist/dev/mp-weixin/app.js
vendored
@@ -8,6 +8,7 @@ if (!Math) {
|
||||
"./pages/login/login.js";
|
||||
"./pages/UserInformation/UserInformation.js";
|
||||
"./pages/Setting/Setting.js";
|
||||
"./pages/NewAddedPk/NewAddedPk.js";
|
||||
"./TUIKit/components/TUIConversation/index.js";
|
||||
"./TUIKit/components/TUIChat/index.js";
|
||||
"./TUIKit/components/TUIChat/video-play.js";
|
||||
|
||||
3
unpackage/dist/dev/mp-weixin/app.json
vendored
3
unpackage/dist/dev/mp-weixin/app.json
vendored
@@ -5,7 +5,8 @@
|
||||
"pages/index/index",
|
||||
"pages/login/login",
|
||||
"pages/UserInformation/UserInformation",
|
||||
"pages/Setting/Setting"
|
||||
"pages/Setting/Setting",
|
||||
"pages/NewAddedPk/NewAddedPk"
|
||||
],
|
||||
"subPackages": [
|
||||
{
|
||||
|
||||
10
unpackage/dist/dev/mp-weixin/common/assets.js
vendored
10
unpackage/dist/dev/mp-weixin/common/assets.js
vendored
@@ -1,6 +1,7 @@
|
||||
"use strict";
|
||||
const _imports_0$4 = "/static/HomeBackground.png";
|
||||
const _imports_0$3 = "/static/Settings.png";
|
||||
const _imports_0$5 = "/static/HomeBackground.png";
|
||||
const _imports_0$4 = "/static/Settings.png";
|
||||
const _imports_0$3 = "/static/Fork.png";
|
||||
const _imports_0$2 = "/static/Navigationimg.png";
|
||||
const _imports_1$1 = "/static/Return.png";
|
||||
const createGroup = "/assets/start-group.6d6b5fbb.svg";
|
||||
@@ -83,10 +84,11 @@ exports.InvitationDark = InvitationDark;
|
||||
exports.InvitationLight = InvitationLight;
|
||||
exports.SearchDefaultIcon = SearchDefaultIcon;
|
||||
exports._imports_0 = _imports_0$2;
|
||||
exports._imports_0$1 = _imports_0$4;
|
||||
exports._imports_0$2 = _imports_0$3;
|
||||
exports._imports_0$1 = _imports_0$5;
|
||||
exports._imports_0$2 = _imports_0$4;
|
||||
exports._imports_0$3 = _imports_0$1;
|
||||
exports._imports_0$4 = _imports_0;
|
||||
exports._imports_0$5 = _imports_0$3;
|
||||
exports._imports_1 = _imports_1$1;
|
||||
exports._imports_1$1 = _imports_1;
|
||||
exports.addSVG = addSVG;
|
||||
|
||||
16
unpackage/dist/dev/mp-weixin/common/vendor.js
vendored
16
unpackage/dist/dev/mp-weixin/common/vendor.js
vendored
@@ -6875,9 +6875,9 @@ function populateParameters(fromRes, toRes) {
|
||||
appVersion: "1.0.0",
|
||||
appVersionCode: "100",
|
||||
appLanguage: getAppLanguage(hostLanguage),
|
||||
uniCompileVersion: "4.65",
|
||||
uniCompilerVersion: "4.65",
|
||||
uniRuntimeVersion: "4.65",
|
||||
uniCompileVersion: "4.66",
|
||||
uniCompilerVersion: "4.66",
|
||||
uniRuntimeVersion: "4.66",
|
||||
uniPlatform: "mp-weixin",
|
||||
deviceBrand,
|
||||
deviceModel: model,
|
||||
@@ -7026,9 +7026,9 @@ const getAppBaseInfo = {
|
||||
appLanguage: getAppLanguage(hostLanguage),
|
||||
isUniAppX: false,
|
||||
uniPlatform: "mp-weixin",
|
||||
uniCompileVersion: "4.65",
|
||||
uniCompilerVersion: "4.65",
|
||||
uniRuntimeVersion: "4.65"
|
||||
uniCompileVersion: "4.66",
|
||||
uniCompilerVersion: "4.66",
|
||||
uniRuntimeVersion: "4.66"
|
||||
};
|
||||
extend(toRes, parameters);
|
||||
}
|
||||
@@ -7768,9 +7768,9 @@ function isConsoleWritable() {
|
||||
return isWritable;
|
||||
}
|
||||
function initRuntimeSocketService() {
|
||||
const hosts = "192.168.0.107,127.0.0.1";
|
||||
const hosts = "192.168.0.111,127.0.0.1";
|
||||
const port = "8090";
|
||||
const id = "mp-weixin_d28YCI";
|
||||
const id = "mp-weixin_XfiXYR";
|
||||
const lazy = typeof swan !== "undefined";
|
||||
let restoreError = lazy ? () => {
|
||||
} : initOnError();
|
||||
|
||||
256
unpackage/dist/dev/mp-weixin/components/NationalDictionary.js
vendored
Normal file
256
unpackage/dist/dev/mp-weixin/components/NationalDictionary.js
vendored
Normal file
@@ -0,0 +1,256 @@
|
||||
"use strict";
|
||||
const NationalDictionary = {
|
||||
AD: "安道尔",
|
||||
AE: "阿拉伯联合酋长国",
|
||||
AF: "阿富汗",
|
||||
AG: "安提瓜和巴布达",
|
||||
AI: "安圭拉",
|
||||
AL: "阿尔巴尼亚",
|
||||
AM: "亚美尼亚",
|
||||
AO: "安哥拉",
|
||||
AQ: "南极洲",
|
||||
AR: "阿根廷",
|
||||
AS: "美属萨摩亚",
|
||||
AT: "奥地利",
|
||||
AU: "澳大利亚",
|
||||
AW: "阿鲁巴",
|
||||
AX: "奥兰群岛",
|
||||
AZ: "阿塞拜疆",
|
||||
BA: "波斯尼亚和黑塞哥维那",
|
||||
BB: "巴巴多斯",
|
||||
BD: "孟加拉国",
|
||||
BE: "比利时",
|
||||
BF: "布基纳法索",
|
||||
BG: "保加利亚",
|
||||
BH: "巴林",
|
||||
BI: "布隆迪",
|
||||
BJ: "贝宁",
|
||||
BL: "圣巴泰勒米",
|
||||
BM: "百慕大群岛",
|
||||
BN: "文莱达鲁萨兰国",
|
||||
BO: "玻利维亚",
|
||||
BQ: "博奈尔、圣尤斯特歇斯和萨巴",
|
||||
BR: "巴西",
|
||||
BS: "巴哈马",
|
||||
BT: "不丹",
|
||||
BV: "布韦岛",
|
||||
BW: "博茨瓦纳",
|
||||
BY: "白俄罗斯",
|
||||
BZ: "伯利兹",
|
||||
CA: "加拿大",
|
||||
CC: "科科斯(基林)群岛",
|
||||
CD: "刚果民主共和国",
|
||||
CF: "中非共和国",
|
||||
CG: "刚果共和国",
|
||||
CH: "瑞士",
|
||||
CI: "科特迪瓦",
|
||||
CK: "库克群岛",
|
||||
CL: "智利",
|
||||
CM: "喀麦隆",
|
||||
CN: "中国",
|
||||
CO: "哥伦比亚",
|
||||
CR: "哥斯达黎加",
|
||||
CU: "古巴",
|
||||
CV: "佛得角",
|
||||
CW: "库拉索",
|
||||
CX: "圣诞岛",
|
||||
CY: "塞浦路斯",
|
||||
CZ: "捷克共和国",
|
||||
DE: "德国",
|
||||
DG: "迪戈加西亚岛",
|
||||
DJ: "吉布提",
|
||||
DK: "丹麦",
|
||||
DM: "多米尼克",
|
||||
DO: "多米尼加共和国",
|
||||
DZ: "阿尔及利亚",
|
||||
EC: "厄瓜多尔",
|
||||
EE: "爱沙尼亚",
|
||||
EG: "埃及",
|
||||
EH: "西撒哈拉",
|
||||
ER: "厄立特里亚",
|
||||
ES: "西班牙",
|
||||
ET: "埃塞俄比亚",
|
||||
FI: "芬兰",
|
||||
FJ: "斐济",
|
||||
FK: "福克兰群岛",
|
||||
FM: "密克罗尼西亚",
|
||||
FO: "法罗群岛",
|
||||
FR: "法国",
|
||||
GA: "加蓬",
|
||||
GB: "英国",
|
||||
GD: "格林纳达",
|
||||
GE: "格鲁吉亚",
|
||||
GF: "法属圭亚那",
|
||||
GG: "根西岛",
|
||||
GH: "加纳",
|
||||
GI: "直布罗陀",
|
||||
GL: "格陵兰",
|
||||
GM: "冈比亚",
|
||||
GN: "几内亚",
|
||||
GP: "瓜德罗普",
|
||||
GQ: "赤道几内亚",
|
||||
GR: "希腊",
|
||||
GS: "南乔治亚和南桑德威奇群岛",
|
||||
GT: "危地马拉",
|
||||
GU: "关岛",
|
||||
GW: "几内亚比绍",
|
||||
GY: "圭亚那",
|
||||
HK: "中国香港特别行政区",
|
||||
HM: "赫德岛和麦克唐纳群岛",
|
||||
HN: "洪都拉斯",
|
||||
HR: "克罗地亚",
|
||||
HT: "海地",
|
||||
HU: "匈牙利",
|
||||
ID: "印度尼西亚",
|
||||
IE: "爱尔兰",
|
||||
IL: "以色列",
|
||||
IM: "马恩岛",
|
||||
IN: "印度",
|
||||
IO: "英属印度洋领地",
|
||||
IQ: "伊拉克",
|
||||
IR: "伊朗",
|
||||
IS: "冰岛",
|
||||
IT: "意大利",
|
||||
JE: "泽西岛",
|
||||
JM: "牙买加",
|
||||
JO: "约旦",
|
||||
JP: "日本",
|
||||
KE: "肯尼亚",
|
||||
KG: "吉尔吉斯斯坦",
|
||||
KH: "柬埔寨",
|
||||
KI: "基里巴斯",
|
||||
KM: "科摩罗",
|
||||
KN: "圣基茨和尼维斯",
|
||||
KP: "朝鲜",
|
||||
KR: "韩国",
|
||||
KW: "科威特",
|
||||
KY: "开曼群岛",
|
||||
KZ: "哈萨克斯坦",
|
||||
LA: "老挝",
|
||||
LB: "黎巴嫩",
|
||||
LC: "圣卢西亚",
|
||||
LI: "列支敦士登",
|
||||
LK: "斯里兰卡",
|
||||
LR: "利比里亚",
|
||||
LS: "莱索托",
|
||||
LT: "立陶宛",
|
||||
LU: "卢森堡",
|
||||
LV: "拉脱维亚",
|
||||
LY: "利比亚",
|
||||
MA: "摩洛哥",
|
||||
MC: "摩纳哥",
|
||||
MD: "摩尔多瓦",
|
||||
ME: "黑山",
|
||||
MF: "圣马丁",
|
||||
MG: "马达加斯加",
|
||||
MH: "马绍尔群岛",
|
||||
MK: "北马其顿",
|
||||
ML: "马里",
|
||||
MM: "缅甸",
|
||||
MN: "蒙古",
|
||||
MO: "中国澳门特别行政区",
|
||||
MP: "北马里亚纳群岛",
|
||||
MQ: "马提尼克",
|
||||
MR: "毛里塔尼亚",
|
||||
MS: "蒙特塞拉特",
|
||||
MT: "马耳他",
|
||||
MU: "毛里求斯",
|
||||
MV: "马尔代夫",
|
||||
MW: "马拉维",
|
||||
MX: "墨西哥",
|
||||
MY: "马来西亚",
|
||||
MZ: "莫桑比克",
|
||||
NA: "纳米比亚",
|
||||
NC: "新喀里多尼亚",
|
||||
NE: "尼日尔",
|
||||
NF: "诺福克岛",
|
||||
NG: "尼日利亚",
|
||||
NI: "尼加拉瓜",
|
||||
NL: "荷兰",
|
||||
NO: "挪威",
|
||||
NP: "尼泊尔",
|
||||
NR: "瑙鲁",
|
||||
NU: "纽埃",
|
||||
NZ: "新西兰",
|
||||
OM: "阿曼",
|
||||
PA: "巴拿马",
|
||||
PE: "秘鲁",
|
||||
PF: "法属玻利尼西亚",
|
||||
PG: "巴布亚新几内亚",
|
||||
PH: "菲律宾",
|
||||
PK: "巴基斯坦",
|
||||
PL: "波兰",
|
||||
PM: "圣皮埃尔和密克隆群岛",
|
||||
PN: "皮特凯恩群岛",
|
||||
PR: "波多黎各",
|
||||
PS: "巴勒斯坦",
|
||||
PT: "葡萄牙",
|
||||
PW: "帕劳",
|
||||
PY: "巴拉圭",
|
||||
QA: "卡塔尔",
|
||||
RE: "留尼汪",
|
||||
RO: "罗马尼亚",
|
||||
RS: "塞尔维亚",
|
||||
RU: "俄罗斯",
|
||||
RW: "卢旺达",
|
||||
SA: "沙特阿拉伯",
|
||||
SB: "索罗门群岛",
|
||||
SC: "塞舌尔",
|
||||
SD: "苏丹",
|
||||
SE: "瑞典",
|
||||
SG: "新加坡",
|
||||
SI: "斯洛文尼亚",
|
||||
SJ: "斯瓦尔巴和扬马延",
|
||||
SK: "斯洛伐克",
|
||||
SL: "塞拉利昂",
|
||||
SM: "圣马利诺",
|
||||
SN: "塞内加尔",
|
||||
SO: "索马里",
|
||||
SR: "苏里南",
|
||||
SS: "南苏丹",
|
||||
ST: "圣多美和普林西比",
|
||||
SV: "萨尔瓦多",
|
||||
SX: "荷属圣马丁",
|
||||
SY: "叙利亚",
|
||||
SZ: "斯威士兰",
|
||||
TC: "特克斯和凯科斯群岛",
|
||||
TD: "乍得",
|
||||
TF: "法属南部领地",
|
||||
TG: "多哥",
|
||||
TH: "泰国",
|
||||
TJ: "塔吉克斯坦",
|
||||
TK: "托克劳群岛",
|
||||
TL: "东帝汶",
|
||||
TM: "土库曼斯坦",
|
||||
TN: "突尼斯",
|
||||
TO: "汤加",
|
||||
TR: "土耳其",
|
||||
TT: "特立尼达和多巴哥",
|
||||
TV: "图瓦卢",
|
||||
TW: "台湾",
|
||||
TZ: "坦桑尼亚",
|
||||
UA: "乌克兰",
|
||||
UG: "乌干达",
|
||||
UM: "美国本土外小岛屿",
|
||||
US: "美国",
|
||||
UY: "乌拉圭",
|
||||
UZ: "乌兹别克斯坦",
|
||||
VA: "梵蒂冈",
|
||||
VC: "圣文森特",
|
||||
VE: "委内瑞拉",
|
||||
VG: "英属维尔京群岛",
|
||||
VI: "美属维尔京群岛",
|
||||
VN: "越南",
|
||||
VU: "瓦努阿图",
|
||||
WS: "萨摩亚",
|
||||
YE: "也门",
|
||||
YT: "马约特岛",
|
||||
ZA: "南非",
|
||||
ZM: "赞比亚",
|
||||
ZW: "津巴布韦",
|
||||
UK: "英国",
|
||||
WF: "瓦利斯"
|
||||
};
|
||||
const countryNamesArray = Object.values(NationalDictionary);
|
||||
exports.countryNamesArray = countryNamesArray;
|
||||
//# sourceMappingURL=../../.sourcemap/mp-weixin/components/NationalDictionary.js.map
|
||||
@@ -1,5 +1,9 @@
|
||||
"use strict";
|
||||
const common_vendor = require("../../common/vendor.js");
|
||||
if (!Math) {
|
||||
NewAddedPk();
|
||||
}
|
||||
const NewAddedPk = () => "../../pages/NewAddedPk/NewAddedPk2.js";
|
||||
const _sfc_main = {
|
||||
__name: "tabBar",
|
||||
props: {
|
||||
@@ -61,11 +65,18 @@ const _sfc_main = {
|
||||
tabList[middleIndex].middleClass = "mid-button";
|
||||
}
|
||||
}
|
||||
common_vendor.ref();
|
||||
const createModule = common_vendor.ref();
|
||||
function openPopupQuantity() {
|
||||
createModule.value.open();
|
||||
}
|
||||
const disabledScroll = () => {
|
||||
return false;
|
||||
};
|
||||
function handlePush(item, index) {
|
||||
if (index === 2) {
|
||||
openPopupQuantity();
|
||||
return;
|
||||
}
|
||||
if (item.text === "消息") {
|
||||
common_vendor.index.navigateTo({ url: "/TUIKit/components/TUIConversation/index" });
|
||||
} else {
|
||||
@@ -82,12 +93,15 @@ const _sfc_main = {
|
||||
b: common_vendor.t(item.text),
|
||||
c: __props.tabIndex == index ? "#1DD2F9" : "#A7A3A3",
|
||||
d: common_vendor.n("list-item flex flex-column flex-middle " + item.middleClass),
|
||||
e: common_vendor.o$1(($event) => handlePush(item), index),
|
||||
e: common_vendor.o$1(($event) => handlePush(item, index), index),
|
||||
f: index
|
||||
};
|
||||
}),
|
||||
b: common_vendor.n(common_vendor.unref(showMiddleButton) === true ? "tab-list-middle" : "tab-list-default"),
|
||||
c: common_vendor.o$1(disabledScroll)
|
||||
c: common_vendor.o$1(disabledScroll),
|
||||
d: common_vendor.sr(createModule, "c497a889-0", {
|
||||
"k": "createModule"
|
||||
})
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {}
|
||||
"usingComponents": {
|
||||
"new-added-pk": "../../pages/NewAddedPk/NewAddedPk"
|
||||
}
|
||||
}
|
||||
@@ -1 +1 @@
|
||||
<view class="tab-block data-v-c497a889"><view class="{{['tab-list', 'flex', 'flex-center', 'data-v-c497a889', b]}}"><view wx:for="{{a}}" wx:for-item="item" wx:key="f" class="{{['data-v-c497a889', item.d]}}" bindtap="{{item.e}}"><view class="item-img-box data-v-c497a889"><image class="item-img data-v-c497a889" src="{{item.a}}"/></view><view class="item-text font-20 data-v-c497a889" style="{{'color:' + item.c}}">{{item.b}}</view></view></view><view class="data-v-c497a889" catchtouchmove="{{c}}"></view></view>
|
||||
<view class="tab-block data-v-c497a889"><view class="{{['tab-list', 'flex', 'flex-center', 'data-v-c497a889', b]}}"><view wx:for="{{a}}" wx:for-item="item" wx:key="f" class="{{['data-v-c497a889', item.d]}}" bindtap="{{item.e}}"><view class="item-img-box data-v-c497a889"><image class="item-img data-v-c497a889" src="{{item.a}}"/></view><view class="item-text font-20 data-v-c497a889" style="{{'color:' + item.c}}">{{item.b}}</view></view></view><view class="data-v-c497a889" catchtouchmove="{{c}}"></view><new-added-pk class="createModule r data-v-c497a889" u-r="createModule" u-i="c497a889-0" bind:__l="__l"></new-added-pk></view>
|
||||
@@ -57,6 +57,13 @@
|
||||
padding: 0;
|
||||
z-index: 0;
|
||||
}
|
||||
.tab-block .createModule.data-v-c497a889 {
|
||||
position: fixed;
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
z-index: 998;
|
||||
width: 100vw;
|
||||
}
|
||||
.tab-block .tab-list-default.data-v-c497a889 {
|
||||
background-color: #ffffff;
|
||||
border-top: 1px #dddddd solid;
|
||||
|
||||
4
unpackage/dist/dev/mp-weixin/pages/NewAddedPk/NewAddedPk.js
vendored
Normal file
4
unpackage/dist/dev/mp-weixin/pages/NewAddedPk/NewAddedPk.js
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
"use strict";
|
||||
const NewAddedPk = require("../../NewAddedPk.js");
|
||||
wx.createPage(NewAddedPk.MiniProgramPage);
|
||||
//# sourceMappingURL=../../../.sourcemap/mp-weixin/pages/NewAddedPk/NewAddedPk.js.map
|
||||
9
unpackage/dist/dev/mp-weixin/pages/NewAddedPk/NewAddedPk.json
vendored
Normal file
9
unpackage/dist/dev/mp-weixin/pages/NewAddedPk/NewAddedPk.json
vendored
Normal file
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"navigationBarTitleText": "新增PK",
|
||||
"usingComponents": {
|
||||
"uni-combox": "../../uni_modules/uni-combox/components/uni-combox/uni-combox",
|
||||
"wht-select": "../../uni_modules/wht-select/components/wht-select/wht-select",
|
||||
"uni-number-box": "../../uni_modules/uni-number-box/components/uni-number-box/uni-number-box",
|
||||
"uni-easyinput": "../../uni_modules/uni-easyinput/components/uni-easyinput/uni-easyinput"
|
||||
}
|
||||
}
|
||||
1
unpackage/dist/dev/mp-weixin/pages/NewAddedPk/NewAddedPk.wxml
vendored
Normal file
1
unpackage/dist/dev/mp-weixin/pages/NewAddedPk/NewAddedPk.wxml
vendored
Normal file
@@ -0,0 +1 @@
|
||||
<view wx:if="{{a}}" class="Mask data-v-96d38e2b" bindtap="{{o}}"><view class="data-v-96d38e2b" catchtap="{{n}}"><view class="container data-v-96d38e2b"><image class="Fork data-v-96d38e2b" bindtap="{{b}}" src="{{c}}" mode="scaleToFill"/><view class="Title data-v-96d38e2b">发布新PK</view><view class="Individual data-v-96d38e2b"><view class="NameAnchor data-v-96d38e2b"><input class="NameAnchorcss data-v-96d38e2b" bindinput="{{d}}" placeholder="主播名称"/></view><view class="Gender data-v-96d38e2b"><uni-combox wx:if="{{f}}" class="Gendercss data-v-96d38e2b" u-i="96d38e2b-0" bind:__l="__l" bindupdateModelValue="{{e}}" u-p="{{f}}"></uni-combox></view></view><view class="Accountnumber data-v-96d38e2b"><wht-select wx:if="{{h}}" class="data-v-96d38e2b" u-i="96d38e2b-1" bind:__l="__l" bindupdateModelValue="{{g}}" u-p="{{h}}"/><view class="Coins data-v-96d38e2b"><uni-number-box wx:if="{{j}}" class="number-box data-v-96d38e2b" u-i="96d38e2b-2" bind:__l="__l" bindupdateModelValue="{{i}}" u-p="{{j}}"></uni-number-box></view></view><view class="Remarkscss data-v-96d38e2b"><uni-easyinput wx:if="{{l}}" class="data-v-96d38e2b" u-i="96d38e2b-3" bind:__l="__l" bindupdateModelValue="{{k}}" u-p="{{l}}"></uni-easyinput></view><view class="Publish data-v-96d38e2b"><button bindtap="{{m}}" class="Publishcss data-v-96d38e2b">发布</button></view></view></view></view>
|
||||
91
unpackage/dist/dev/mp-weixin/pages/NewAddedPk/NewAddedPk.wxss
vendored
Normal file
91
unpackage/dist/dev/mp-weixin/pages/NewAddedPk/NewAddedPk.wxss
vendored
Normal file
@@ -0,0 +1,91 @@
|
||||
|
||||
.Mask.data-v-96d38e2b{
|
||||
width: 100vw;
|
||||
height: 100vh;
|
||||
background: #00000076;
|
||||
display: flex;
|
||||
flex-direction: column-reverse;
|
||||
}
|
||||
.container.data-v-96d38e2b {
|
||||
display: flex;
|
||||
background-color: #fff;
|
||||
flex-direction: column;
|
||||
width: 100%;
|
||||
height: 900rpx;
|
||||
}
|
||||
.Fork.data-v-96d38e2b{
|
||||
width: 50rpx;
|
||||
height: 50rpx;
|
||||
margin-top: 20rpx;
|
||||
/* margin-bottom: 40rpx; */
|
||||
margin-left: 90%;
|
||||
}
|
||||
.Title.data-v-96d38e2b{
|
||||
width: 100%;
|
||||
height: 30rpx;
|
||||
font-size: 50rpx;
|
||||
font-weight: bold;
|
||||
text-align: center;
|
||||
margin-top: 40rpx;
|
||||
margin-bottom: 40rpx;
|
||||
}
|
||||
.Individual.data-v-96d38e2b{
|
||||
display: flex;
|
||||
/* justify-content: center; */
|
||||
}
|
||||
.NameAnchor.data-v-96d38e2b{
|
||||
margin: 40rpx;
|
||||
}
|
||||
.NameAnchorcss.data-v-96d38e2b{
|
||||
width: 300rpx;
|
||||
height: 85rpx;
|
||||
border: 1rpx solid #ccc;
|
||||
border-radius: 10rpx;
|
||||
text-align: center;
|
||||
}
|
||||
.Gender.data-v-96d38e2b{
|
||||
margin: 40rpx;
|
||||
}
|
||||
.Gendercss.data-v-96d38e2b{
|
||||
width: 300rpx;
|
||||
height: 80rpx;
|
||||
text-align: center;
|
||||
}
|
||||
.Accountnumber.data-v-96d38e2b{
|
||||
display: flex;
|
||||
}
|
||||
.Country.data-v-96d38e2b{
|
||||
}
|
||||
.Countrycss.data-v-96d38e2b{
|
||||
margin: 40rpx;
|
||||
width: 300rpx;
|
||||
height: 65rpx;
|
||||
text-align: center;
|
||||
}
|
||||
.Coins.data-v-96d38e2b{
|
||||
margin: 40rpx;
|
||||
width: 300rpx;
|
||||
height: 65rpx;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
.number-box.data-v-96d38e2b {
|
||||
text-align: center;
|
||||
}
|
||||
.Remarkscss.data-v-96d38e2b{
|
||||
width: 90%;
|
||||
margin-top: 30rpx;
|
||||
margin-left: 5%;
|
||||
margin-right: 5%;
|
||||
margin-bottom: 50rpx;
|
||||
border-radius: 10rpx;
|
||||
}
|
||||
.Publish.data-v-96d38e2b{
|
||||
margin-bottom: 50rpx;
|
||||
width: 90%;
|
||||
margin-left: 5%;
|
||||
}
|
||||
.Publishcss.data-v-96d38e2b{
|
||||
background-color: #0048ff94;
|
||||
}
|
||||
4
unpackage/dist/dev/mp-weixin/pages/NewAddedPk/NewAddedPk2.js
vendored
Normal file
4
unpackage/dist/dev/mp-weixin/pages/NewAddedPk/NewAddedPk2.js
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
"use strict";
|
||||
const NewAddedPk = require("../../NewAddedPk.js");
|
||||
wx.createPage(NewAddedPk.MiniProgramPage);
|
||||
//# sourceMappingURL=../../../.sourcemap/mp-weixin/pages/NewAddedPk/NewAddedPk2.js.map
|
||||
BIN
unpackage/dist/dev/mp-weixin/static/Fork.png
vendored
Normal file
BIN
unpackage/dist/dev/mp-weixin/static/Fork.png
vendored
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 5.4 KiB |
161
unpackage/dist/dev/mp-weixin/uni_modules/uni-combox/components/uni-combox/uni-combox.js
vendored
Normal file
161
unpackage/dist/dev/mp-weixin/uni_modules/uni-combox/components/uni-combox/uni-combox.js
vendored
Normal file
@@ -0,0 +1,161 @@
|
||||
"use strict";
|
||||
const common_vendor = require("../../../../common/vendor.js");
|
||||
const _sfc_main = {
|
||||
name: "uniCombox",
|
||||
emits: ["input", "update:modelValue"],
|
||||
props: {
|
||||
clearAble: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
border: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
},
|
||||
label: {
|
||||
type: String,
|
||||
default: ""
|
||||
},
|
||||
labelWidth: {
|
||||
type: String,
|
||||
default: "auto"
|
||||
},
|
||||
placeholder: {
|
||||
type: String,
|
||||
default: ""
|
||||
},
|
||||
candidates: {
|
||||
type: Array,
|
||||
default() {
|
||||
return [];
|
||||
}
|
||||
},
|
||||
emptyTips: {
|
||||
type: String,
|
||||
default: "无匹配项"
|
||||
},
|
||||
modelValue: {
|
||||
type: [String, Number],
|
||||
default: ""
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
showSelector: false,
|
||||
inputVal: ""
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
labelStyle() {
|
||||
if (this.labelWidth === "auto") {
|
||||
return "";
|
||||
}
|
||||
return `width: ${this.labelWidth}`;
|
||||
},
|
||||
filterCandidates() {
|
||||
return this.candidates.filter((item) => {
|
||||
return item.toString().indexOf(this.inputVal) > -1;
|
||||
});
|
||||
},
|
||||
filterCandidatesLength() {
|
||||
return this.filterCandidates.length;
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
modelValue: {
|
||||
handler(newVal) {
|
||||
this.inputVal = newVal;
|
||||
},
|
||||
immediate: true
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
toggleSelector() {
|
||||
this.showSelector = !this.showSelector;
|
||||
},
|
||||
onFocus() {
|
||||
this.showSelector = true;
|
||||
},
|
||||
onBlur() {
|
||||
setTimeout(() => {
|
||||
this.showSelector = false;
|
||||
}, 153);
|
||||
},
|
||||
onSelectorClick(index) {
|
||||
this.inputVal = this.filterCandidates[index];
|
||||
this.showSelector = false;
|
||||
this.$emit("input", this.inputVal);
|
||||
this.$emit("update:modelValue", this.inputVal);
|
||||
},
|
||||
onInput() {
|
||||
setTimeout(() => {
|
||||
this.$emit("input", this.inputVal);
|
||||
this.$emit("update:modelValue", this.inputVal);
|
||||
});
|
||||
},
|
||||
clean() {
|
||||
this.inputVal = "";
|
||||
this.onInput();
|
||||
}
|
||||
}
|
||||
};
|
||||
if (!Array) {
|
||||
const _easycom_uni_icons2 = common_vendor.resolveComponent("uni-icons");
|
||||
_easycom_uni_icons2();
|
||||
}
|
||||
const _easycom_uni_icons = () => "../../../uni-icons/components/uni-icons/uni-icons.js";
|
||||
if (!Math) {
|
||||
_easycom_uni_icons();
|
||||
}
|
||||
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
||||
return common_vendor.e({
|
||||
a: $props.label
|
||||
}, $props.label ? {
|
||||
b: common_vendor.t($props.label),
|
||||
c: common_vendor.s($options.labelStyle)
|
||||
} : {}, {
|
||||
d: $props.placeholder,
|
||||
e: common_vendor.o$1([($event) => $data.inputVal = $event.detail.value, (...args) => $options.onInput && $options.onInput(...args)]),
|
||||
f: common_vendor.o$1((...args) => $options.onFocus && $options.onFocus(...args)),
|
||||
g: common_vendor.o$1((...args) => $options.onBlur && $options.onBlur(...args)),
|
||||
h: $data.inputVal,
|
||||
i: !$data.inputVal || !$props.clearAble
|
||||
}, !$data.inputVal || !$props.clearAble ? {
|
||||
j: common_vendor.o$1($options.toggleSelector),
|
||||
k: common_vendor.p({
|
||||
type: $data.showSelector ? "top" : "bottom",
|
||||
size: "30",
|
||||
color: "#999"
|
||||
})
|
||||
} : {}, {
|
||||
l: $data.inputVal && $props.clearAble
|
||||
}, $data.inputVal && $props.clearAble ? {
|
||||
m: common_vendor.o$1($options.clean),
|
||||
n: common_vendor.p({
|
||||
type: "clear",
|
||||
size: "24",
|
||||
color: "#999",
|
||||
width: "60rpx",
|
||||
height: "60rpx"
|
||||
})
|
||||
} : {}, {
|
||||
o: $data.showSelector
|
||||
}, $data.showSelector ? common_vendor.e({
|
||||
p: $options.filterCandidatesLength === 0
|
||||
}, $options.filterCandidatesLength === 0 ? {
|
||||
q: common_vendor.t($props.emptyTips)
|
||||
} : {}, {
|
||||
r: common_vendor.f($options.filterCandidates, (item, index, i0) => {
|
||||
return {
|
||||
a: common_vendor.t(item),
|
||||
b: index,
|
||||
c: common_vendor.o$1(($event) => $options.onSelectorClick(index), index)
|
||||
};
|
||||
})
|
||||
}) : {}, {
|
||||
s: common_vendor.n($props.border ? "" : "uni-combox__no-border")
|
||||
});
|
||||
}
|
||||
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-e602780e"]]);
|
||||
wx.createComponent(Component);
|
||||
//# sourceMappingURL=../../../../../.sourcemap/mp-weixin/uni_modules/uni-combox/components/uni-combox/uni-combox.js.map
|
||||
6
unpackage/dist/dev/mp-weixin/uni_modules/uni-combox/components/uni-combox/uni-combox.json
vendored
Normal file
6
unpackage/dist/dev/mp-weixin/uni_modules/uni-combox/components/uni-combox/uni-combox.json
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {
|
||||
"uni-icons": "../../../uni-icons/components/uni-icons/uni-icons"
|
||||
}
|
||||
}
|
||||
1
unpackage/dist/dev/mp-weixin/uni_modules/uni-combox/components/uni-combox/uni-combox.wxml
vendored
Normal file
1
unpackage/dist/dev/mp-weixin/uni_modules/uni-combox/components/uni-combox/uni-combox.wxml
vendored
Normal file
@@ -0,0 +1 @@
|
||||
<view class="{{['uni-combox', 'data-v-e602780e', s]}}"><view wx:if="{{a}}" class="uni-combox__label data-v-e602780e" style="{{c}}"><text class="data-v-e602780e">{{b}}</text></view><view class="uni-combox__input-box data-v-e602780e"><input class="uni-combox__input data-v-e602780e" type="text" placeholder="{{d}}" placeholder-class="uni-combox__input-plac" bindinput="{{e}}" bindfocus="{{f}}" bindblur="{{g}}" value="{{h}}"/><uni-icons wx:if="{{i}}" class="data-v-e602780e" bindclick="{{j}}" u-i="e602780e-0" bind:__l="__l" u-p="{{k}}"></uni-icons><uni-icons wx:if="{{l}}" class="data-v-e602780e" bindclick="{{m}}" u-i="e602780e-1" bind:__l="__l" u-p="{{n}}"></uni-icons></view><view wx:if="{{o}}" class="uni-combox__selector data-v-e602780e"><view class="uni-popper__arrow data-v-e602780e"></view><scroll-view scroll-y="true" class="uni-combox__selector-scroll data-v-e602780e"><view wx:if="{{p}}" class="uni-combox__selector-empty data-v-e602780e"><text class="data-v-e602780e">{{q}}</text></view><view wx:for="{{r}}" wx:for-item="item" wx:key="b" class="uni-combox__selector-item data-v-e602780e" bindtap="{{item.c}}"><text class="data-v-e602780e">{{item.a}}</text></view></scroll-view></view></view>
|
||||
126
unpackage/dist/dev/mp-weixin/uni_modules/uni-combox/components/uni-combox/uni-combox.wxss
vendored
Normal file
126
unpackage/dist/dev/mp-weixin/uni_modules/uni-combox/components/uni-combox/uni-combox.wxss
vendored
Normal file
@@ -0,0 +1,126 @@
|
||||
/**
|
||||
* 这里是uni-app内置的常用样式变量
|
||||
*
|
||||
* uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量
|
||||
* 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App
|
||||
*
|
||||
*/
|
||||
/**
|
||||
* 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能
|
||||
*
|
||||
* 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件
|
||||
*/
|
||||
/* 颜色变量 */
|
||||
/* 行为相关颜色 */
|
||||
/* 文字基本颜色 */
|
||||
/* 背景颜色 */
|
||||
/* 边框颜色 */
|
||||
/* 尺寸变量 */
|
||||
/* 文字尺寸 */
|
||||
/* 图片尺寸 */
|
||||
/* Border Radius */
|
||||
/* 水平间距 */
|
||||
/* 垂直间距 */
|
||||
/* 透明度 */
|
||||
/* 文章场景相关 */
|
||||
.uni-combox.data-v-e602780e {
|
||||
font-size: 14px;
|
||||
border: 1px solid #DCDFE6;
|
||||
border-radius: 4px;
|
||||
padding: 6px 10px;
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
}
|
||||
.uni-combox__icon.data-v-e602780e {
|
||||
border: 1px solid #004cff;
|
||||
width: 70rpx;
|
||||
height: 70rpx;
|
||||
}
|
||||
.uni-combox__label.data-v-e602780e {
|
||||
font-size: 16px;
|
||||
line-height: 22px;
|
||||
padding-right: 10px;
|
||||
color: #999999;
|
||||
}
|
||||
.uni-combox__input-box.data-v-e602780e {
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex: 1;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
}
|
||||
.uni-combox__input.data-v-e602780e {
|
||||
flex: 1;
|
||||
font-size: 14px;
|
||||
height: 22px;
|
||||
line-height: 22px;
|
||||
}
|
||||
.uni-combox__input-plac.data-v-e602780e {
|
||||
font-size: 14px;
|
||||
color: #999;
|
||||
}
|
||||
.uni-combox__selector.data-v-e602780e {
|
||||
box-sizing: border-box;
|
||||
position: absolute;
|
||||
top: calc(100% + 12px);
|
||||
left: 0;
|
||||
width: 100%;
|
||||
background-color: #FFFFFF;
|
||||
border: 1px solid #EBEEF5;
|
||||
border-radius: 6px;
|
||||
box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
|
||||
z-index: 2;
|
||||
padding: 4px 0;
|
||||
}
|
||||
.uni-combox__selector-scroll.data-v-e602780e {
|
||||
position: relative;
|
||||
z-index: 999;
|
||||
max-height: 200px;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
.uni-combox__selector-empty.data-v-e602780e,
|
||||
.uni-combox__selector-item.data-v-e602780e {
|
||||
display: flex;
|
||||
cursor: pointer;
|
||||
line-height: 36px;
|
||||
font-size: 14px;
|
||||
text-align: center;
|
||||
padding: 0px 10px;
|
||||
}
|
||||
.uni-combox__selector-item.data-v-e602780e:hover {
|
||||
background-color: #f9f9f9;
|
||||
}
|
||||
.uni-combox__selector-empty.data-v-e602780e:last-child,
|
||||
.uni-combox__selector-item.data-v-e602780e:last-child {
|
||||
border-bottom: none;
|
||||
}
|
||||
.uni-popper__arrow.data-v-e602780e,
|
||||
.uni-popper__arrow.data-v-e602780e::after {
|
||||
position: absolute;
|
||||
display: block;
|
||||
width: 0;
|
||||
height: 0;
|
||||
border-color: transparent;
|
||||
border-style: solid;
|
||||
border-width: 6px;
|
||||
}
|
||||
.uni-popper__arrow.data-v-e602780e {
|
||||
filter: drop-shadow(0 2px 12px rgba(0, 0, 0, 0.03));
|
||||
top: -6px;
|
||||
left: 10%;
|
||||
margin-right: 3px;
|
||||
border-top-width: 0;
|
||||
border-bottom-color: #EBEEF5;
|
||||
}
|
||||
.uni-popper__arrow.data-v-e602780e::after {
|
||||
content: " ";
|
||||
top: 1px;
|
||||
margin-left: -6px;
|
||||
border-top-width: 0;
|
||||
border-bottom-color: #fff;
|
||||
}
|
||||
.uni-combox__no-border.data-v-e602780e {
|
||||
border: none;
|
||||
}
|
||||
476
unpackage/dist/dev/mp-weixin/uni_modules/uni-easyinput/components/uni-easyinput/uni-easyinput.js
vendored
Normal file
476
unpackage/dist/dev/mp-weixin/uni_modules/uni-easyinput/components/uni-easyinput/uni-easyinput.js
vendored
Normal file
@@ -0,0 +1,476 @@
|
||||
"use strict";
|
||||
const common_vendor = require("../../../../common/vendor.js");
|
||||
function obj2strClass(obj) {
|
||||
let classess = "";
|
||||
for (let key in obj) {
|
||||
const val = obj[key];
|
||||
if (val) {
|
||||
classess += `${key} `;
|
||||
}
|
||||
}
|
||||
return classess;
|
||||
}
|
||||
function obj2strStyle(obj) {
|
||||
let style = "";
|
||||
for (let key in obj) {
|
||||
const val = obj[key];
|
||||
style += `${key}:${val};`;
|
||||
}
|
||||
return style;
|
||||
}
|
||||
const _sfc_main = {
|
||||
name: "uni-easyinput",
|
||||
emits: [
|
||||
"click",
|
||||
"iconClick",
|
||||
"update:modelValue",
|
||||
"input",
|
||||
"focus",
|
||||
"blur",
|
||||
"confirm",
|
||||
"clear",
|
||||
"eyes",
|
||||
"change",
|
||||
"keyboardheightchange"
|
||||
],
|
||||
model: {
|
||||
prop: "modelValue",
|
||||
event: "update:modelValue"
|
||||
},
|
||||
options: {
|
||||
virtualHost: true
|
||||
},
|
||||
inject: {
|
||||
form: {
|
||||
from: "uniForm",
|
||||
default: null
|
||||
},
|
||||
formItem: {
|
||||
from: "uniFormItem",
|
||||
default: null
|
||||
}
|
||||
},
|
||||
props: {
|
||||
name: String,
|
||||
value: [Number, String],
|
||||
modelValue: [Number, String],
|
||||
type: {
|
||||
type: String,
|
||||
default: "text"
|
||||
},
|
||||
clearable: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
},
|
||||
autoHeight: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
placeholder: {
|
||||
type: String,
|
||||
default: " "
|
||||
},
|
||||
placeholderStyle: String,
|
||||
focus: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
disabled: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
maxlength: {
|
||||
type: [Number, String],
|
||||
default: 140
|
||||
},
|
||||
confirmType: {
|
||||
type: String,
|
||||
default: "done"
|
||||
},
|
||||
clearSize: {
|
||||
type: [Number, String],
|
||||
default: 24
|
||||
},
|
||||
inputBorder: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
},
|
||||
prefixIcon: {
|
||||
type: String,
|
||||
default: ""
|
||||
},
|
||||
suffixIcon: {
|
||||
type: String,
|
||||
default: ""
|
||||
},
|
||||
trim: {
|
||||
type: [Boolean, String],
|
||||
default: false
|
||||
},
|
||||
cursorSpacing: {
|
||||
type: Number,
|
||||
default: 0
|
||||
},
|
||||
passwordIcon: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
},
|
||||
adjustPosition: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
},
|
||||
primaryColor: {
|
||||
type: String,
|
||||
default: "#2979ff"
|
||||
},
|
||||
styles: {
|
||||
type: Object,
|
||||
default() {
|
||||
return {
|
||||
color: "#333",
|
||||
backgroundColor: "#fff",
|
||||
disableColor: "#F7F6F6",
|
||||
borderColor: "#e5e5e5"
|
||||
};
|
||||
}
|
||||
},
|
||||
errorMessage: {
|
||||
type: [String, Boolean],
|
||||
default: ""
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
focused: false,
|
||||
val: "",
|
||||
showMsg: "",
|
||||
border: false,
|
||||
isFirstBorder: false,
|
||||
showClearIcon: false,
|
||||
showPassword: false,
|
||||
focusShow: false,
|
||||
localMsg: "",
|
||||
isEnter: false
|
||||
// 用于判断当前是否是使用回车操作
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
// 输入框内是否有值
|
||||
isVal() {
|
||||
const val = this.val;
|
||||
if (val || val === 0) {
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
},
|
||||
msg() {
|
||||
return this.localMsg || this.errorMessage;
|
||||
},
|
||||
// 因为uniapp的input组件的maxlength组件必须要数值,这里转为数值,用户可以传入字符串数值
|
||||
inputMaxlength() {
|
||||
return Number(this.maxlength);
|
||||
},
|
||||
// 处理外层样式的style
|
||||
boxStyle() {
|
||||
return `color:${this.inputBorder && this.msg ? "#e43d33" : this.styles.color};`;
|
||||
},
|
||||
// input 内容的类和样式处理
|
||||
inputContentClass() {
|
||||
return obj2strClass({
|
||||
"is-input-border": this.inputBorder,
|
||||
"is-input-error-border": this.inputBorder && this.msg,
|
||||
"is-textarea": this.type === "textarea",
|
||||
"is-disabled": this.disabled,
|
||||
"is-focused": this.focusShow
|
||||
});
|
||||
},
|
||||
inputContentStyle() {
|
||||
const focusColor = this.focusShow ? this.primaryColor : this.styles.borderColor;
|
||||
const borderColor = this.inputBorder && this.msg ? "#dd524d" : focusColor;
|
||||
return obj2strStyle({
|
||||
"border-color": borderColor || "#e5e5e5",
|
||||
"background-color": this.disabled ? this.styles.disableColor : this.styles.backgroundColor
|
||||
});
|
||||
},
|
||||
// input右侧样式
|
||||
inputStyle() {
|
||||
const paddingRight = this.type === "password" || this.clearable || this.prefixIcon ? "" : "10px";
|
||||
return obj2strStyle({
|
||||
"padding-right": paddingRight,
|
||||
"padding-left": this.prefixIcon ? "" : "10px"
|
||||
});
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
value(newVal) {
|
||||
if (newVal === null) {
|
||||
this.val = "";
|
||||
return;
|
||||
}
|
||||
this.val = newVal;
|
||||
},
|
||||
modelValue(newVal) {
|
||||
if (newVal === null) {
|
||||
this.val = "";
|
||||
return;
|
||||
}
|
||||
this.val = newVal;
|
||||
},
|
||||
focus(newVal) {
|
||||
this.$nextTick(() => {
|
||||
this.focused = this.focus;
|
||||
this.focusShow = this.focus;
|
||||
});
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.init();
|
||||
if (this.form && this.formItem) {
|
||||
this.$watch("formItem.errMsg", (newVal) => {
|
||||
this.localMsg = newVal;
|
||||
});
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.$nextTick(() => {
|
||||
this.focused = this.focus;
|
||||
this.focusShow = this.focus;
|
||||
});
|
||||
},
|
||||
methods: {
|
||||
/**
|
||||
* 初始化变量值
|
||||
*/
|
||||
init() {
|
||||
if (this.value || this.value === 0) {
|
||||
this.val = this.value;
|
||||
} else if (this.modelValue || this.modelValue === 0 || this.modelValue === "") {
|
||||
this.val = this.modelValue;
|
||||
} else {
|
||||
this.val = "";
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 点击图标时触发
|
||||
* @param {Object} type
|
||||
*/
|
||||
onClickIcon(type) {
|
||||
this.$emit("iconClick", type);
|
||||
},
|
||||
/**
|
||||
* 显示隐藏内容,密码框时生效
|
||||
*/
|
||||
onEyes() {
|
||||
this.showPassword = !this.showPassword;
|
||||
this.$emit("eyes", this.showPassword);
|
||||
},
|
||||
/**
|
||||
* 输入时触发
|
||||
* @param {Object} event
|
||||
*/
|
||||
onInput(event) {
|
||||
let value = event.detail.value;
|
||||
if (this.trim) {
|
||||
if (typeof this.trim === "boolean" && this.trim) {
|
||||
value = this.trimStr(value);
|
||||
}
|
||||
if (typeof this.trim === "string") {
|
||||
value = this.trimStr(value, this.trim);
|
||||
}
|
||||
}
|
||||
if (this.errMsg)
|
||||
this.errMsg = "";
|
||||
this.val = value;
|
||||
this.$emit("input", value);
|
||||
this.$emit("update:modelValue", value);
|
||||
},
|
||||
/**
|
||||
* 外部调用方法
|
||||
* 获取焦点时触发
|
||||
* @param {Object} event
|
||||
*/
|
||||
onFocus() {
|
||||
this.$nextTick(() => {
|
||||
this.focused = true;
|
||||
});
|
||||
this.$emit("focus", null);
|
||||
},
|
||||
_Focus(event) {
|
||||
this.focusShow = true;
|
||||
this.$emit("focus", event);
|
||||
},
|
||||
/**
|
||||
* 外部调用方法
|
||||
* 失去焦点时触发
|
||||
* @param {Object} event
|
||||
*/
|
||||
onBlur() {
|
||||
this.focused = false;
|
||||
this.$emit("blur", null);
|
||||
},
|
||||
_Blur(event) {
|
||||
event.detail.value;
|
||||
this.focusShow = false;
|
||||
this.$emit("blur", event);
|
||||
if (this.isEnter === false) {
|
||||
this.$emit("change", this.val);
|
||||
}
|
||||
if (this.form && this.formItem) {
|
||||
const { validateTrigger } = this.form;
|
||||
if (validateTrigger === "blur") {
|
||||
this.formItem.onFieldChange();
|
||||
}
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 按下键盘的发送键
|
||||
* @param {Object} e
|
||||
*/
|
||||
onConfirm(e) {
|
||||
this.$emit("confirm", this.val);
|
||||
this.isEnter = true;
|
||||
this.$emit("change", this.val);
|
||||
this.$nextTick(() => {
|
||||
this.isEnter = false;
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 清理内容
|
||||
* @param {Object} event
|
||||
*/
|
||||
onClear(event) {
|
||||
this.val = "";
|
||||
this.$emit("input", "");
|
||||
this.$emit("update:modelValue", "");
|
||||
this.$emit("clear");
|
||||
},
|
||||
/**
|
||||
* 键盘高度发生变化的时候触发此事件
|
||||
* 兼容性:微信小程序2.7.0+、App 3.1.0+
|
||||
* @param {Object} event
|
||||
*/
|
||||
onkeyboardheightchange(event) {
|
||||
this.$emit("keyboardheightchange", event);
|
||||
},
|
||||
/**
|
||||
* 去除空格
|
||||
*/
|
||||
trimStr(str, pos = "both") {
|
||||
if (pos === "both") {
|
||||
return str.trim();
|
||||
} else if (pos === "left") {
|
||||
return str.trimLeft();
|
||||
} else if (pos === "right") {
|
||||
return str.trimRight();
|
||||
} else if (pos === "start") {
|
||||
return str.trimStart();
|
||||
} else if (pos === "end") {
|
||||
return str.trimEnd();
|
||||
} else if (pos === "all") {
|
||||
return str.replace(/\s+/g, "");
|
||||
} else if (pos === "none") {
|
||||
return str;
|
||||
}
|
||||
return str;
|
||||
}
|
||||
}
|
||||
};
|
||||
if (!Array) {
|
||||
const _easycom_uni_icons2 = common_vendor.resolveComponent("uni-icons");
|
||||
_easycom_uni_icons2();
|
||||
}
|
||||
const _easycom_uni_icons = () => "../../../uni-icons/components/uni-icons/uni-icons.js";
|
||||
if (!Math) {
|
||||
_easycom_uni_icons();
|
||||
}
|
||||
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
||||
return common_vendor.e({
|
||||
a: $props.prefixIcon
|
||||
}, $props.prefixIcon ? {
|
||||
b: common_vendor.o$1(($event) => $options.onClickIcon("prefix")),
|
||||
c: common_vendor.p({
|
||||
type: $props.prefixIcon,
|
||||
color: "#c0c4cc",
|
||||
size: "22"
|
||||
})
|
||||
} : {}, {
|
||||
d: $props.type === "textarea"
|
||||
}, $props.type === "textarea" ? {
|
||||
e: $props.inputBorder ? 1 : "",
|
||||
f: $props.name,
|
||||
g: $data.val,
|
||||
h: $props.placeholder,
|
||||
i: $props.placeholderStyle,
|
||||
j: $props.disabled,
|
||||
k: $options.inputMaxlength,
|
||||
l: $data.focused,
|
||||
m: $props.autoHeight,
|
||||
n: $props.cursorSpacing,
|
||||
o: $props.adjustPosition,
|
||||
p: common_vendor.o$1((...args) => $options.onInput && $options.onInput(...args)),
|
||||
q: common_vendor.o$1((...args) => $options._Blur && $options._Blur(...args)),
|
||||
r: common_vendor.o$1((...args) => $options._Focus && $options._Focus(...args)),
|
||||
s: common_vendor.o$1((...args) => $options.onConfirm && $options.onConfirm(...args)),
|
||||
t: common_vendor.o$1((...args) => $options.onkeyboardheightchange && $options.onkeyboardheightchange(...args))
|
||||
} : {
|
||||
v: $props.type === "password" ? "text" : $props.type,
|
||||
w: common_vendor.s($options.inputStyle),
|
||||
x: $props.name,
|
||||
y: $data.val,
|
||||
z: !$data.showPassword && $props.type === "password",
|
||||
A: $props.placeholder,
|
||||
B: $props.placeholderStyle,
|
||||
C: $props.disabled,
|
||||
D: $options.inputMaxlength,
|
||||
E: $data.focused,
|
||||
F: $props.confirmType,
|
||||
G: $props.cursorSpacing,
|
||||
H: $props.adjustPosition,
|
||||
I: common_vendor.o$1((...args) => $options._Focus && $options._Focus(...args)),
|
||||
J: common_vendor.o$1((...args) => $options._Blur && $options._Blur(...args)),
|
||||
K: common_vendor.o$1((...args) => $options.onInput && $options.onInput(...args)),
|
||||
L: common_vendor.o$1((...args) => $options.onConfirm && $options.onConfirm(...args)),
|
||||
M: common_vendor.o$1((...args) => $options.onkeyboardheightchange && $options.onkeyboardheightchange(...args))
|
||||
}, {
|
||||
N: $props.type === "password" && $props.passwordIcon
|
||||
}, $props.type === "password" && $props.passwordIcon ? common_vendor.e({
|
||||
O: $options.isVal
|
||||
}, $options.isVal ? {
|
||||
P: $props.type === "textarea" ? 1 : "",
|
||||
Q: common_vendor.o$1($options.onEyes),
|
||||
R: common_vendor.p({
|
||||
type: $data.showPassword ? "eye-slash-filled" : "eye-filled",
|
||||
size: 22,
|
||||
color: $data.focusShow ? $props.primaryColor : "#c0c4cc"
|
||||
})
|
||||
} : {}) : {}, {
|
||||
S: $props.suffixIcon
|
||||
}, $props.suffixIcon ? common_vendor.e({
|
||||
T: $props.suffixIcon
|
||||
}, $props.suffixIcon ? {
|
||||
U: common_vendor.o$1(($event) => $options.onClickIcon("suffix")),
|
||||
V: common_vendor.p({
|
||||
type: $props.suffixIcon,
|
||||
color: "#c0c4cc",
|
||||
size: "22"
|
||||
})
|
||||
} : {}) : common_vendor.e({
|
||||
W: $props.clearable && $options.isVal && !$props.disabled && $props.type !== "textarea"
|
||||
}, $props.clearable && $options.isVal && !$props.disabled && $props.type !== "textarea" ? {
|
||||
X: $props.type === "textarea" ? 1 : "",
|
||||
Y: common_vendor.o$1($options.onClear),
|
||||
Z: common_vendor.p({
|
||||
type: "clear",
|
||||
size: $props.clearSize,
|
||||
color: $options.msg ? "#dd524d" : $data.focusShow ? $props.primaryColor : "#c0c4cc"
|
||||
})
|
||||
} : {}), {
|
||||
aa: common_vendor.n($options.inputContentClass),
|
||||
ab: common_vendor.s($options.inputContentStyle),
|
||||
ac: $options.msg ? 1 : "",
|
||||
ad: common_vendor.s($options.boxStyle)
|
||||
});
|
||||
}
|
||||
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render]]);
|
||||
wx.createComponent(Component);
|
||||
//# sourceMappingURL=../../../../../.sourcemap/mp-weixin/uni_modules/uni-easyinput/components/uni-easyinput/uni-easyinput.js.map
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {
|
||||
"uni-icons": "../../../uni-icons/components/uni-icons/uni-icons"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
<view class="{{['uni-easyinput', ac && 'uni-easyinput-error']}}" style="{{ad}}"><view class="{{['uni-easyinput__content', aa]}}" style="{{ab}}"><uni-icons wx:if="{{a}}" class="content-clear-icon" catchclick="{{b}}" u-i="61595fa3-0" bind:__l="__l" u-p="{{c}}"></uni-icons><slot name="left"></slot><textarea wx:if="{{d}}" class="{{['uni-easyinput__content-textarea', e && 'input-padding']}}" name="{{f}}" value="{{g}}" placeholder="{{h}}" placeholderStyle="{{i}}" disabled="{{j}}" placeholder-class="uni-easyinput__placeholder-class" maxlength="{{k}}" focus="{{l}}" autoHeight="{{m}}" cursor-spacing="{{n}}" adjust-position="{{o}}" bindinput="{{p}}" bindblur="{{q}}" bindfocus="{{r}}" bindconfirm="{{s}}" bindkeyboardheightchange="{{t}}"></textarea><block wx:else><input wx:if="{{r0}}" type="{{v}}" class="uni-easyinput__content-input" style="{{w}}" name="{{x}}" value="{{y}}" password="{{z}}" placeholder="{{A}}" placeholderStyle="{{B}}" placeholder-class="uni-easyinput__placeholder-class" disabled="{{C}}" maxlength="{{D}}" focus="{{E}}" confirmType="{{F}}" cursor-spacing="{{G}}" adjust-position="{{H}}" bindfocus="{{I}}" bindblur="{{J}}" bindinput="{{K}}" bindconfirm="{{L}}" bindkeyboardheightchange="{{M}}"/></block><block wx:if="{{N}}"><uni-icons wx:if="{{O}}" class="{{['content-clear-icon', P && 'is-textarea-icon']}}" bindclick="{{Q}}" u-i="61595fa3-1" bind:__l="__l" u-p="{{R}}"></uni-icons></block><block wx:if="{{S}}"><uni-icons wx:if="{{T}}" class="content-clear-icon" catchclick="{{U}}" u-i="61595fa3-2" bind:__l="__l" u-p="{{V}}"></uni-icons></block><block wx:else><uni-icons wx:if="{{W}}" class="{{['content-clear-icon', X && 'is-textarea-icon']}}" bindclick="{{Y}}" u-i="61595fa3-3" bind:__l="__l" u-p="{{Z}}"></uni-icons></block><slot name="right"></slot></view></view>
|
||||
144
unpackage/dist/dev/mp-weixin/uni_modules/uni-easyinput/components/uni-easyinput/uni-easyinput.wxss
vendored
Normal file
144
unpackage/dist/dev/mp-weixin/uni_modules/uni-easyinput/components/uni-easyinput/uni-easyinput.wxss
vendored
Normal file
@@ -0,0 +1,144 @@
|
||||
/**
|
||||
* 这里是uni-app内置的常用样式变量
|
||||
*
|
||||
* uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量
|
||||
* 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App
|
||||
*
|
||||
*/
|
||||
/**
|
||||
* 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能
|
||||
*
|
||||
* 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件
|
||||
*/
|
||||
/* 颜色变量 */
|
||||
/* 行为相关颜色 */
|
||||
/* 文字基本颜色 */
|
||||
/* 背景颜色 */
|
||||
/* 边框颜色 */
|
||||
/* 尺寸变量 */
|
||||
/* 文字尺寸 */
|
||||
/* 图片尺寸 */
|
||||
/* Border Radius */
|
||||
/* 水平间距 */
|
||||
/* 垂直间距 */
|
||||
/* 透明度 */
|
||||
/* 文章场景相关 */
|
||||
.uni-easyinput {
|
||||
width: 100%;
|
||||
flex: 1;
|
||||
position: relative;
|
||||
text-align: left;
|
||||
color: #333;
|
||||
font-size: 14px;
|
||||
}
|
||||
.uni-easyinput__content {
|
||||
flex: 1;
|
||||
width: 100%;
|
||||
display: flex;
|
||||
box-sizing: border-box;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
border-color: #fff;
|
||||
transition-property: border-color;
|
||||
transition-duration: 0.3s;
|
||||
}
|
||||
.uni-easyinput__content-input {
|
||||
width: auto;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
flex: 1;
|
||||
line-height: 1;
|
||||
font-size: 14px;
|
||||
height: 35px;
|
||||
/*ifdef H5*/
|
||||
/*endif*/
|
||||
}
|
||||
.uni-easyinput__content-input ::-ms-reveal {
|
||||
display: none;
|
||||
}
|
||||
.uni-easyinput__content-input ::-ms-clear {
|
||||
display: none;
|
||||
}
|
||||
.uni-easyinput__content-input ::-o-clear {
|
||||
display: none;
|
||||
}
|
||||
.uni-easyinput__placeholder-class {
|
||||
color: #999;
|
||||
font-size: 12px;
|
||||
}
|
||||
.is-textarea {
|
||||
align-items: flex-start;
|
||||
}
|
||||
.is-textarea-icon {
|
||||
margin-top: 5px;
|
||||
}
|
||||
.uni-easyinput__content-textarea {
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
flex: 1;
|
||||
line-height: 1.5;
|
||||
font-size: 14px;
|
||||
margin: 6px;
|
||||
margin-left: 0;
|
||||
height: 80px;
|
||||
min-height: 80px;
|
||||
min-height: 80px;
|
||||
width: auto;
|
||||
}
|
||||
.input-padding {
|
||||
padding-left: 10px;
|
||||
}
|
||||
.content-clear-icon {
|
||||
padding: 0 5px;
|
||||
}
|
||||
.label-icon {
|
||||
margin-right: 5px;
|
||||
margin-top: -1px;
|
||||
}
|
||||
.is-input-border {
|
||||
display: flex;
|
||||
box-sizing: border-box;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
border: 1px solid #dcdfe6;
|
||||
border-radius: 4px;
|
||||
}
|
||||
.uni-error-message {
|
||||
position: absolute;
|
||||
bottom: -17px;
|
||||
left: 0;
|
||||
line-height: 12px;
|
||||
color: #e43d33;
|
||||
font-size: 12px;
|
||||
text-align: left;
|
||||
}
|
||||
.uni-error-msg--boeder {
|
||||
position: relative;
|
||||
bottom: 0;
|
||||
line-height: 22px;
|
||||
}
|
||||
.is-input-error-border {
|
||||
border-color: #e43d33;
|
||||
}
|
||||
.is-input-error-border .uni-easyinput__placeholder-class {
|
||||
color: #f29e99;
|
||||
}
|
||||
.uni-easyinput--border {
|
||||
margin-bottom: 0;
|
||||
padding: 10px 15px;
|
||||
border-top: 1px #eee solid;
|
||||
}
|
||||
.uni-easyinput-error {
|
||||
padding-bottom: 0;
|
||||
}
|
||||
.is-first-border {
|
||||
border: none;
|
||||
}
|
||||
.is-disabled {
|
||||
background-color: #f7f6f6;
|
||||
color: #d5d5d5;
|
||||
}
|
||||
.is-disabled .uni-easyinput__placeholder-class {
|
||||
color: #d5d5d5;
|
||||
font-size: 12px;
|
||||
}
|
||||
73
unpackage/dist/dev/mp-weixin/uni_modules/uni-icons/components/uni-icons/uni-icons.js
vendored
Normal file
73
unpackage/dist/dev/mp-weixin/uni_modules/uni-icons/components/uni-icons/uni-icons.js
vendored
Normal file
@@ -0,0 +1,73 @@
|
||||
"use strict";
|
||||
const uni_modules_uniIcons_components_uniIcons_uniicons_file_vue = require("./uniicons_file_vue.js");
|
||||
const common_vendor = require("../../../../common/vendor.js");
|
||||
const getVal = (val) => {
|
||||
const reg = /^[0-9]*$/g;
|
||||
return typeof val === "number" || reg.test(val) ? val + "px" : val;
|
||||
};
|
||||
const _sfc_main = {
|
||||
name: "UniIcons",
|
||||
emits: ["click"],
|
||||
props: {
|
||||
type: {
|
||||
type: String,
|
||||
default: ""
|
||||
},
|
||||
color: {
|
||||
type: String,
|
||||
default: "#333333"
|
||||
},
|
||||
size: {
|
||||
type: [Number, String],
|
||||
default: 16
|
||||
},
|
||||
customPrefix: {
|
||||
type: String,
|
||||
default: ""
|
||||
},
|
||||
fontFamily: {
|
||||
type: String,
|
||||
default: ""
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
icons: uni_modules_uniIcons_components_uniIcons_uniicons_file_vue.fontData
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
unicode() {
|
||||
let code = this.icons.find((v) => v.font_class === this.type);
|
||||
if (code) {
|
||||
return code.unicode;
|
||||
}
|
||||
return "";
|
||||
},
|
||||
iconSize() {
|
||||
return getVal(this.size);
|
||||
},
|
||||
styleObj() {
|
||||
if (this.fontFamily !== "") {
|
||||
return `color: ${this.color}; font-size: ${this.iconSize}; font-family: ${this.fontFamily};`;
|
||||
}
|
||||
return `color: ${this.color}; font-size: ${this.iconSize};`;
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
_onClick() {
|
||||
this.$emit("click");
|
||||
}
|
||||
}
|
||||
};
|
||||
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
||||
return {
|
||||
a: common_vendor.s($options.styleObj),
|
||||
b: common_vendor.n("uniui-" + $props.type),
|
||||
c: common_vendor.n($props.customPrefix),
|
||||
d: common_vendor.n($props.customPrefix ? $props.type : ""),
|
||||
e: common_vendor.o$1((...args) => $options._onClick && $options._onClick(...args))
|
||||
};
|
||||
}
|
||||
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render]]);
|
||||
wx.createComponent(Component);
|
||||
//# sourceMappingURL=../../../../../.sourcemap/mp-weixin/uni_modules/uni-icons/components/uni-icons/uni-icons.js.map
|
||||
4
unpackage/dist/dev/mp-weixin/uni_modules/uni-icons/components/uni-icons/uni-icons.json
vendored
Normal file
4
unpackage/dist/dev/mp-weixin/uni_modules/uni-icons/components/uni-icons/uni-icons.json
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {}
|
||||
}
|
||||
1
unpackage/dist/dev/mp-weixin/uni_modules/uni-icons/components/uni-icons/uni-icons.wxml
vendored
Normal file
1
unpackage/dist/dev/mp-weixin/uni_modules/uni-icons/components/uni-icons/uni-icons.wxml
vendored
Normal file
@@ -0,0 +1 @@
|
||||
<text style="{{a}}" class="{{['uni-icons', b, c, d]}}" bindtap="{{e}}"><slot></slot></text>
|
||||
532
unpackage/dist/dev/mp-weixin/uni_modules/uni-icons/components/uni-icons/uni-icons.wxss
vendored
Normal file
532
unpackage/dist/dev/mp-weixin/uni_modules/uni-icons/components/uni-icons/uni-icons.wxss
vendored
Normal file
File diff suppressed because one or more lines are too long
649
unpackage/dist/dev/mp-weixin/uni_modules/uni-icons/components/uni-icons/uniicons_file_vue.js
vendored
Normal file
649
unpackage/dist/dev/mp-weixin/uni_modules/uni-icons/components/uni-icons/uniicons_file_vue.js
vendored
Normal file
@@ -0,0 +1,649 @@
|
||||
"use strict";
|
||||
const fontData = [
|
||||
{
|
||||
"font_class": "arrow-down",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "arrow-left",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "arrow-right",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "arrow-up",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "auth",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "auth-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "back",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "bars",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "calendar",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "calendar-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "camera",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "camera-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "cart",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "cart-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "chat",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "chat-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "chatboxes",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "chatboxes-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "chatbubble",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "chatbubble-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "checkbox",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "checkbox-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "checkmarkempty",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "circle",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "circle-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "clear",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "close",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "closeempty",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "cloud-download",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "cloud-download-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "cloud-upload",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "cloud-upload-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "color",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "color-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "compose",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "contact",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "contact-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "down",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "bottom",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "download",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "download-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "email",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "email-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "eye",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "eye-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "eye-slash",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "eye-slash-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "fire",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "fire-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "flag",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "flag-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "folder-add",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "folder-add-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "font",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "forward",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "gear",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "gear-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "gift",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "gift-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "hand-down",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "hand-down-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "hand-up",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "hand-up-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "headphones",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "heart",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "heart-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "help",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "help-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "home",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "home-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "image",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "image-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "images",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "images-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "info",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "info-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "left",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "link",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "list",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "location",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "location-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "locked",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "locked-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "loop",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "mail-open",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "mail-open-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "map",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "map-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "map-pin",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "map-pin-ellipse",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "medal",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "medal-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "mic",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "mic-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "micoff",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "micoff-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "minus",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "minus-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "more",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "more-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "navigate",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "navigate-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "notification",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "notification-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "paperclip",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "paperplane",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "paperplane-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "person",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "person-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "personadd",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "personadd-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "personadd-filled-copy",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "phone",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "phone-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "plus",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "plus-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "plusempty",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "pulldown",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "pyq",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "qq",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "redo",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "redo-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "refresh",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "refresh-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "refreshempty",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "reload",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "right",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "scan",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "search",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "settings",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "settings-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "shop",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "shop-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "smallcircle",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "smallcircle-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "sound",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "sound-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "spinner-cycle",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "staff",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "staff-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "star",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "star-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "starhalf",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "trash",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "trash-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "tune",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "tune-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "undo",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "undo-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "up",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "top",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "upload",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "upload-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "videocam",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "videocam-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "vip",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "vip-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "wallet",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "wallet-filled",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "weibo",
|
||||
"unicode": ""
|
||||
},
|
||||
{
|
||||
"font_class": "weixin",
|
||||
"unicode": ""
|
||||
}
|
||||
];
|
||||
exports.fontData = fontData;
|
||||
//# sourceMappingURL=../../../../../.sourcemap/mp-weixin/uni_modules/uni-icons/components/uni-icons/uniicons_file_vue.js.map
|
||||
155
unpackage/dist/dev/mp-weixin/uni_modules/uni-number-box/components/uni-number-box/uni-number-box.js
vendored
Normal file
155
unpackage/dist/dev/mp-weixin/uni_modules/uni-number-box/components/uni-number-box/uni-number-box.js
vendored
Normal file
@@ -0,0 +1,155 @@
|
||||
"use strict";
|
||||
const common_vendor = require("../../../../common/vendor.js");
|
||||
const _sfc_main = {
|
||||
name: "UniNumberBox",
|
||||
emits: ["change", "input", "update:modelValue", "blur", "focus"],
|
||||
props: {
|
||||
value: {
|
||||
type: [Number, String],
|
||||
default: 1
|
||||
},
|
||||
modelValue: {
|
||||
type: [Number, String],
|
||||
default: 1
|
||||
},
|
||||
min: {
|
||||
type: Number,
|
||||
default: 0
|
||||
},
|
||||
max: {
|
||||
type: Number,
|
||||
default: 100
|
||||
},
|
||||
step: {
|
||||
type: Number,
|
||||
default: 1
|
||||
},
|
||||
background: {
|
||||
type: String,
|
||||
default: "#f5f5f5"
|
||||
},
|
||||
color: {
|
||||
type: String,
|
||||
default: "#333"
|
||||
},
|
||||
disabled: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
width: {
|
||||
type: Number,
|
||||
default: 40
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
inputValue: 0
|
||||
};
|
||||
},
|
||||
watch: {
|
||||
value(val) {
|
||||
this.inputValue = +val;
|
||||
},
|
||||
modelValue(val) {
|
||||
this.inputValue = +val;
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
widthWithPx() {
|
||||
return this.width + "px";
|
||||
}
|
||||
},
|
||||
created() {
|
||||
if (this.value === 1) {
|
||||
this.inputValue = +this.modelValue;
|
||||
}
|
||||
if (this.modelValue === 1) {
|
||||
this.inputValue = +this.value;
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
_calcValue(type) {
|
||||
if (this.disabled) {
|
||||
return;
|
||||
}
|
||||
const scale = this._getDecimalScale();
|
||||
let value = this.inputValue * scale;
|
||||
let step = this.step * scale;
|
||||
if (type === "minus") {
|
||||
value -= step;
|
||||
if (value < this.min * scale) {
|
||||
return;
|
||||
}
|
||||
if (value > this.max * scale) {
|
||||
value = this.max * scale;
|
||||
}
|
||||
}
|
||||
if (type === "plus") {
|
||||
value += step;
|
||||
if (value > this.max * scale) {
|
||||
return;
|
||||
}
|
||||
if (value < this.min * scale) {
|
||||
value = this.min * scale;
|
||||
}
|
||||
}
|
||||
this.inputValue = (value / scale).toFixed(String(scale).length - 1);
|
||||
this.$emit("input", +this.inputValue);
|
||||
this.$emit("update:modelValue", +this.inputValue);
|
||||
this.$emit("change", +this.inputValue);
|
||||
},
|
||||
_getDecimalScale() {
|
||||
let scale = 1;
|
||||
if (~~this.step !== this.step) {
|
||||
scale = Math.pow(10, String(this.step).split(".")[1].length);
|
||||
}
|
||||
return scale;
|
||||
},
|
||||
_onBlur(event) {
|
||||
this.$emit("blur", event);
|
||||
let value = event.detail.value;
|
||||
if (isNaN(value)) {
|
||||
this.inputValue = this.value;
|
||||
return;
|
||||
}
|
||||
value = +value;
|
||||
if (value > this.max) {
|
||||
value = this.max;
|
||||
} else if (value < this.min) {
|
||||
value = this.min;
|
||||
}
|
||||
const scale = this._getDecimalScale();
|
||||
this.inputValue = value.toFixed(String(scale).length - 1);
|
||||
this.$emit("input", +this.inputValue);
|
||||
this.$emit("update:modelValue", +this.inputValue);
|
||||
this.$emit("change", +this.inputValue);
|
||||
},
|
||||
_onFocus(event) {
|
||||
this.$emit("focus", event);
|
||||
}
|
||||
}
|
||||
};
|
||||
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
||||
return {
|
||||
a: $data.inputValue <= $props.min || $props.disabled ? 1 : "",
|
||||
b: $props.color,
|
||||
c: common_vendor.o$1(($event) => $options._calcValue("minus")),
|
||||
d: $props.background,
|
||||
e: $props.disabled,
|
||||
f: common_vendor.o$1((...args) => $options._onFocus && $options._onFocus(...args)),
|
||||
g: common_vendor.o$1((...args) => $options._onBlur && $options._onBlur(...args)),
|
||||
h: $props.step < 1 ? "digit" : "number",
|
||||
i: $props.background,
|
||||
j: $props.color,
|
||||
k: $options.widthWithPx,
|
||||
l: $data.inputValue,
|
||||
m: common_vendor.o$1(($event) => $data.inputValue = $event.detail.value),
|
||||
n: $data.inputValue >= $props.max || $props.disabled ? 1 : "",
|
||||
o: $props.color,
|
||||
p: common_vendor.o$1(($event) => $options._calcValue("plus")),
|
||||
q: $props.background
|
||||
};
|
||||
}
|
||||
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render]]);
|
||||
wx.createComponent(Component);
|
||||
//# sourceMappingURL=../../../../../.sourcemap/mp-weixin/uni_modules/uni-number-box/components/uni-number-box/uni-number-box.js.map
|
||||
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {}
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
<view class="uni-numbox"><view bindtap="{{c}}" class="uni-numbox__minus uni-numbox-btns" style="{{'background:' + d}}"><text class="{{['uni-numbox--text', a && 'uni-numbox--disabled']}}" style="{{'color:' + b}}">-</text></view><block wx:if="{{r0}}"><input disabled="{{e}}" bindfocus="{{f}}" bindblur="{{g}}" class="uni-numbox__value" type="{{h}}" style="{{'background:' + i + ';' + ('color:' + j) + ';' + ('width:' + k)}}" value="{{l}}" bindinput="{{m}}"/></block><view bindtap="{{p}}" class="uni-numbox__plus uni-numbox-btns" style="{{'background:' + q}}"><text class="{{['uni-numbox--text', n && 'uni-numbox--disabled']}}" style="{{'color:' + o}}">+</text></view></view>
|
||||
@@ -0,0 +1,65 @@
|
||||
/**
|
||||
* 这里是uni-app内置的常用样式变量
|
||||
*
|
||||
* uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量
|
||||
* 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App
|
||||
*
|
||||
*/
|
||||
/**
|
||||
* 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能
|
||||
*
|
||||
* 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件
|
||||
*/
|
||||
/* 颜色变量 */
|
||||
/* 行为相关颜色 */
|
||||
/* 文字基本颜色 */
|
||||
/* 背景颜色 */
|
||||
/* 边框颜色 */
|
||||
/* 尺寸变量 */
|
||||
/* 文字尺寸 */
|
||||
/* 图片尺寸 */
|
||||
/* Border Radius */
|
||||
/* 水平间距 */
|
||||
/* 垂直间距 */
|
||||
/* 透明度 */
|
||||
/* 文章场景相关 */
|
||||
.uni-numbox {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
}
|
||||
.uni-numbox-btns {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
padding: 0 8px;
|
||||
background-color: #f5f5f5;
|
||||
}
|
||||
.uni-numbox__value {
|
||||
margin: 0 2px;
|
||||
background-color: #f5f5f5;
|
||||
width: 40px;
|
||||
height: 26px;
|
||||
text-align: center;
|
||||
font-size: 14px;
|
||||
border-width: 0;
|
||||
color: #333;
|
||||
}
|
||||
.uni-numbox__minus {
|
||||
border-top-left-radius: 2px;
|
||||
border-bottom-left-radius: 2px;
|
||||
}
|
||||
.uni-numbox__plus {
|
||||
border-top-right-radius: 2px;
|
||||
border-bottom-right-radius: 2px;
|
||||
}
|
||||
.uni-numbox--text {
|
||||
line-height: 20px;
|
||||
margin-bottom: 2px;
|
||||
font-size: 20px;
|
||||
font-weight: 300;
|
||||
color: #333;
|
||||
}
|
||||
.uni-numbox .uni-numbox--disabled {
|
||||
color: #c0c0c0 !important;
|
||||
}
|
||||
191
unpackage/dist/dev/mp-weixin/uni_modules/wht-select/components/wht-select/wht-select.js
vendored
Normal file
191
unpackage/dist/dev/mp-weixin/uni_modules/wht-select/components/wht-select/wht-select.js
vendored
Normal file
@@ -0,0 +1,191 @@
|
||||
"use strict";
|
||||
const common_vendor = require("../../../../common/vendor.js");
|
||||
const _sfc_main = {
|
||||
name: "wht-select",
|
||||
props: {
|
||||
options: {
|
||||
type: Array,
|
||||
default: () => []
|
||||
},
|
||||
value: {
|
||||
type: [String, Number],
|
||||
default: ""
|
||||
},
|
||||
placeholder: {
|
||||
type: String,
|
||||
default: "请选择"
|
||||
},
|
||||
disabled: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
clearable: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
// 样式相关的props
|
||||
height: {
|
||||
type: Number,
|
||||
default: 40
|
||||
},
|
||||
fontSize: {
|
||||
type: Number,
|
||||
default: 14
|
||||
},
|
||||
borderColor: {
|
||||
type: String,
|
||||
default: "#dcdfe6"
|
||||
},
|
||||
borderRadius: {
|
||||
type: Number,
|
||||
default: 4
|
||||
},
|
||||
backgroundColor: {
|
||||
type: String,
|
||||
default: "#ffffff"
|
||||
},
|
||||
textColor: {
|
||||
type: String,
|
||||
default: "#606266"
|
||||
},
|
||||
placeholderColor: {
|
||||
type: String,
|
||||
default: "#c0c4cc"
|
||||
},
|
||||
activeColor: {
|
||||
type: String,
|
||||
default: "#409eff"
|
||||
},
|
||||
filterable: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
searchPlaceholder: {
|
||||
type: String,
|
||||
default: "请输入搜索内容"
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
currentValue: "",
|
||||
isOpen: false,
|
||||
searchQuery: ""
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
currentLabel() {
|
||||
const option = this.options.find((item) => item.value === this.currentValue);
|
||||
return option ? option.label : "";
|
||||
},
|
||||
filteredOptions() {
|
||||
if (!this.filterable || !this.searchQuery) {
|
||||
return this.options;
|
||||
}
|
||||
return this.options.filter(
|
||||
(item) => item.label.toLowerCase().includes(this.searchQuery.toLowerCase())
|
||||
);
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
value: {
|
||||
handler(newVal) {
|
||||
this.currentValue = newVal;
|
||||
},
|
||||
immediate: true
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
togglePicker() {
|
||||
if (this.disabled)
|
||||
return;
|
||||
this.isOpen = !this.isOpen;
|
||||
if (!this.isOpen) {
|
||||
this.searchQuery = "";
|
||||
}
|
||||
},
|
||||
selectOption(item, index) {
|
||||
if (item.disabled)
|
||||
return;
|
||||
this.currentValue = item.value;
|
||||
this.searchQuery = "";
|
||||
this.$emit("input", item.value);
|
||||
this.$emit("change", item);
|
||||
this.isOpen = false;
|
||||
},
|
||||
clearValue(e) {
|
||||
this.currentValue = "";
|
||||
this.searchQuery = "";
|
||||
this.$emit("input", "");
|
||||
this.$emit("change", null);
|
||||
this.$emit("clear");
|
||||
},
|
||||
onSearch() {
|
||||
this.$emit("search", this.searchQuery);
|
||||
},
|
||||
handleFocus() {
|
||||
if (!this.disabled) {
|
||||
this.isOpen = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
||||
return common_vendor.e({
|
||||
a: $props.filterable
|
||||
}, $props.filterable ? {
|
||||
b: $data.currentValue ? $options.currentLabel : $props.placeholder,
|
||||
c: $props.fontSize + "px",
|
||||
d: $data.currentValue ? $props.textColor : $props.placeholderColor,
|
||||
e: common_vendor.o$1(() => {
|
||||
}),
|
||||
f: common_vendor.o$1([($event) => $data.searchQuery = $event.detail.value, (...args) => $options.onSearch && $options.onSearch(...args)]),
|
||||
g: common_vendor.o$1((...args) => $options.handleFocus && $options.handleFocus(...args)),
|
||||
h: $data.searchQuery
|
||||
} : {
|
||||
i: common_vendor.t($options.currentLabel || $props.placeholder),
|
||||
j: $props.fontSize + "px",
|
||||
k: $data.currentValue ? $props.textColor : $props.placeholderColor
|
||||
}, {
|
||||
l: $props.clearable && $data.currentValue && !$props.disabled
|
||||
}, $props.clearable && $data.currentValue && !$props.disabled ? {
|
||||
m: common_vendor.o$1((...args) => $options.clearValue && $options.clearValue(...args))
|
||||
} : {
|
||||
n: $props.placeholderColor
|
||||
}, {
|
||||
o: $data.isOpen ? 1 : "",
|
||||
p: !$data.currentValue ? 1 : "",
|
||||
q: $props.height + "px",
|
||||
r: $props.backgroundColor,
|
||||
s: $props.borderColor,
|
||||
t: $props.borderRadius + "px",
|
||||
v: common_vendor.o$1((...args) => $options.togglePicker && $options.togglePicker(...args)),
|
||||
w: $data.isOpen
|
||||
}, $data.isOpen ? common_vendor.e({
|
||||
x: common_vendor.o$1((...args) => $options.togglePicker && $options.togglePicker(...args)),
|
||||
y: $options.filteredOptions.length > 0
|
||||
}, $options.filteredOptions.length > 0 ? {
|
||||
z: common_vendor.f($options.filteredOptions, (item, index, i0) => {
|
||||
return {
|
||||
a: common_vendor.t(item.label),
|
||||
b: item.value,
|
||||
c: item.disabled ? 1 : "",
|
||||
d: $data.currentValue === item.value ? 1 : "",
|
||||
e: item.disabled ? $props.placeholderColor : $props.textColor,
|
||||
f: $data.currentValue === item.value ? $props.activeColor + "20" : $props.backgroundColor,
|
||||
g: common_vendor.o$1(($event) => $options.selectOption(item, index), item.value)
|
||||
};
|
||||
}),
|
||||
A: $props.fontSize + "px"
|
||||
} : {
|
||||
B: $props.fontSize + "px",
|
||||
C: $props.placeholderColor
|
||||
}, {
|
||||
D: $props.backgroundColor,
|
||||
E: $props.borderRadius + "px"
|
||||
}) : {}, {
|
||||
F: $props.disabled ? 1 : ""
|
||||
});
|
||||
}
|
||||
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-57f09195"]]);
|
||||
wx.createComponent(Component);
|
||||
//# sourceMappingURL=../../../../../.sourcemap/mp-weixin/uni_modules/wht-select/components/wht-select/wht-select.js.map
|
||||
4
unpackage/dist/dev/mp-weixin/uni_modules/wht-select/components/wht-select/wht-select.json
vendored
Normal file
4
unpackage/dist/dev/mp-weixin/uni_modules/wht-select/components/wht-select/wht-select.json
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"component": true,
|
||||
"usingComponents": {}
|
||||
}
|
||||
1
unpackage/dist/dev/mp-weixin/uni_modules/wht-select/components/wht-select/wht-select.wxml
vendored
Normal file
1
unpackage/dist/dev/mp-weixin/uni_modules/wht-select/components/wht-select/wht-select.wxml
vendored
Normal file
@@ -0,0 +1 @@
|
||||
<view class="{{['wht-select-wrapper', 'data-v-57f09195', F && 'is-disabled']}}"><view class="{{['wht-select-inner', 'data-v-57f09195', o && 'is-active', p && 'is-placeholder']}}" style="{{'height:' + q + ';' + ('background-color:' + r) + ';' + ('border-color:' + s) + ';' + ('border-radius:' + t)}}" bindtap="{{v}}"><view class="wht-select-value data-v-57f09195"><input wx:if="{{a}}" class="wht-select-input data-v-57f09195" placeholder="{{b}}" style="{{'font-size:' + c + ';' + ('color:' + d)}}" catchtap="{{e}}" bindinput="{{f}}" bindfocus="{{g}}" value="{{h}}"/><text wx:else class="data-v-57f09195" style="{{'font-size:' + j + ';' + ('color:' + k)}}">{{i}}</text></view><view class="wht-select-suffix data-v-57f09195"><view wx:if="{{l}}" class="wht-select-clear data-v-57f09195" catchtap="{{m}}">×</view><view wx:else class="wht-select-arrow data-v-57f09195" style="{{'border-top-color:' + n}}"></view></view></view><view wx:if="{{w}}" class="select-dropdown data-v-57f09195"><view class="select-dropdown-mask data-v-57f09195" catchtap="{{x}}"></view><view class="select-dropdown-content data-v-57f09195" style="{{'background-color:' + D + ';' + ('border-radius:' + E)}}"><block wx:if="{{y}}"><view wx:for="{{z}}" wx:for-item="item" wx:key="b" class="{{['data-v-57f09195', item.c && 'disabled', item.d && 'active']}}" style="{{'font-size:' + A + ';' + ('color:' + item.e) + ';' + ('background-color:' + item.f)}}" catchtap="{{item.g}}">{{item.a}}</view></block><view wx:else class="select-dropdown-empty data-v-57f09195" style="{{'font-size:' + B + ';' + ('color:' + C)}}"> 暂无数据 </view></view></view></view>
|
||||
181
unpackage/dist/dev/mp-weixin/uni_modules/wht-select/components/wht-select/wht-select.wxss
vendored
Normal file
181
unpackage/dist/dev/mp-weixin/uni_modules/wht-select/components/wht-select/wht-select.wxss
vendored
Normal file
@@ -0,0 +1,181 @@
|
||||
/**
|
||||
* 这里是uni-app内置的常用样式变量
|
||||
*
|
||||
* uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量
|
||||
* 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App
|
||||
*
|
||||
*/
|
||||
/**
|
||||
* 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能
|
||||
*
|
||||
* 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件
|
||||
*/
|
||||
/* 颜色变量 */
|
||||
/* 行为相关颜色 */
|
||||
/* 文字基本颜色 */
|
||||
/* 背景颜色 */
|
||||
/* 边框颜色 */
|
||||
/* 尺寸变量 */
|
||||
/* 文字尺寸 */
|
||||
/* 图片尺寸 */
|
||||
/* Border Radius */
|
||||
/* 水平间距 */
|
||||
/* 垂直间距 */
|
||||
/* 透明度 */
|
||||
/* 文章场景相关 */
|
||||
.wht-select-wrapper.data-v-57f09195 {
|
||||
width: 100%;
|
||||
position: relative;
|
||||
}
|
||||
.wht-select-wrapper .wht-select-inner.data-v-57f09195 {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
border-width: 1px;
|
||||
border-style: solid;
|
||||
transition: all 0.2s;
|
||||
cursor: pointer;
|
||||
}
|
||||
.wht-select-wrapper .wht-select-inner.is-active .wht-select-arrow.data-v-57f09195 {
|
||||
transform: rotate(180deg);
|
||||
}
|
||||
.wht-select-wrapper .wht-select-value.data-v-57f09195 {
|
||||
position: absolute;
|
||||
left: 12px;
|
||||
right: 30px;
|
||||
top: 50%;
|
||||
transform: translateY(-50%);
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
height: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
.wht-select-wrapper .wht-select-suffix.data-v-57f09195 {
|
||||
position: absolute;
|
||||
right: 8px;
|
||||
top: 50%;
|
||||
transform: translateY(-50%);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
.wht-select-wrapper .wht-select-clear.data-v-57f09195 {
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
line-height: 16px;
|
||||
text-align: center;
|
||||
border-radius: 50%;
|
||||
background-color: #c0c4cc;
|
||||
color: #fff;
|
||||
font-size: 12px;
|
||||
cursor: pointer;
|
||||
transition: all 0.2s;
|
||||
}
|
||||
.wht-select-wrapper .wht-select-clear.data-v-57f09195:hover {
|
||||
background-color: #909399;
|
||||
}
|
||||
.wht-select-wrapper .wht-select-arrow.data-v-57f09195 {
|
||||
width: 0;
|
||||
height: 0;
|
||||
border-left: 5px solid transparent;
|
||||
border-right: 5px solid transparent;
|
||||
border-top: 5px solid;
|
||||
transition: transform 0.2s;
|
||||
}
|
||||
.wht-select-wrapper .select-dropdown.data-v-57f09195 {
|
||||
position: absolute;
|
||||
top: 100%;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
margin-top: 4px;
|
||||
z-index: 999;
|
||||
}
|
||||
.wht-select-wrapper .select-dropdown-mask.data-v-57f09195 {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
z-index: 998;
|
||||
}
|
||||
.wht-select-wrapper .select-dropdown-content.data-v-57f09195 {
|
||||
position: relative;
|
||||
max-height: 240px;
|
||||
border: 1px solid #e4e7ed;
|
||||
box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
|
||||
z-index: 999;
|
||||
overflow-y: auto;
|
||||
}
|
||||
.wht-select-wrapper .select-dropdown-content.data-v-57f09195::-webkit-scrollbar {
|
||||
width: 6px;
|
||||
}
|
||||
.wht-select-wrapper .select-dropdown-content.data-v-57f09195::-webkit-scrollbar-thumb {
|
||||
background-color: #e4e7ed;
|
||||
border-radius: 3px;
|
||||
}
|
||||
.wht-select-wrapper .select-dropdown-content > view.data-v-57f09195 {
|
||||
padding: 0 12px;
|
||||
height: 36px;
|
||||
line-height: 36px;
|
||||
cursor: pointer;
|
||||
}
|
||||
.wht-select-wrapper .select-dropdown-content > view.disabled.data-v-57f09195 {
|
||||
cursor: not-allowed;
|
||||
}
|
||||
.wht-select-wrapper .select-dropdown-content .select-dropdown-search.data-v-57f09195 {
|
||||
padding: 8px;
|
||||
border-bottom: 1px solid #e4e7ed;
|
||||
}
|
||||
.wht-select-wrapper .select-dropdown-content .select-dropdown-search input.data-v-57f09195 {
|
||||
width: 100%;
|
||||
height: 32px;
|
||||
padding: 0 8px;
|
||||
border: 1px solid #dcdfe6;
|
||||
border-radius: 4px;
|
||||
font-size: 14px;
|
||||
}
|
||||
.wht-select-wrapper .select-dropdown-content .select-dropdown-search input.data-v-57f09195:focus {
|
||||
border-color: #409eff;
|
||||
outline: none;
|
||||
}
|
||||
.wht-select-wrapper .select-dropdown-content .select-dropdown-empty.data-v-57f09195 {
|
||||
padding: 12px;
|
||||
text-align: center;
|
||||
}
|
||||
.wht-select-wrapper .wht-select-input.data-v-57f09195 {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background: transparent;
|
||||
border: none;
|
||||
outline: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
line-height: normal;
|
||||
}
|
||||
.wht-select-wrapper .wht-select-input.data-v-57f09195::-webkit-input-placeholder {
|
||||
color: inherit;
|
||||
line-height: normal;
|
||||
}
|
||||
.wht-select-wrapper .wht-select-input.data-v-57f09195::placeholder {
|
||||
color: inherit;
|
||||
line-height: normal;
|
||||
}
|
||||
@media (prefers-color-scheme: dark) {
|
||||
.wht-select-wrapper .select-dropdown-content.data-v-57f09195 {
|
||||
box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.3);
|
||||
}
|
||||
.wht-select-wrapper .select-dropdown-content.data-v-57f09195::-webkit-scrollbar-thumb {
|
||||
background-color: #48484a;
|
||||
}
|
||||
.wht-select-wrapper .select-dropdown-content .select-dropdown-search.data-v-57f09195 {
|
||||
border-bottom-color: #48484a;
|
||||
}
|
||||
.wht-select-wrapper .select-dropdown-content .select-dropdown-search input.data-v-57f09195 {
|
||||
border-color: #48484a;
|
||||
background-color: #1c1c1e;
|
||||
color: #fff;
|
||||
}
|
||||
.wht-select-wrapper .select-dropdown-content .select-dropdown-search input.data-v-57f09195:focus {
|
||||
border-color: #409eff;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user