cty-mui-core 1.0.10 → 1.0.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/cty-image-viewer.js +1 -1
- package/components/cty-loading.js +1 -1
- package/components/cty-record.js +1 -1
- package/components/cty-share-sheet.js +3 -2
- package/components/index.js +3 -2
- package/components/permission-purpose.js +1 -1
- package/components/swipe.js +2 -1
- package/dist/cjs/cty-image-viewer.cjs.entry.js +1 -1
- package/dist/cjs/cty-loading.cjs.entry.js +1 -1
- package/dist/cjs/cty-permission-purpose.cjs.entry.js +1 -1
- package/dist/cjs/cty-record.cjs.entry.js +1 -1
- package/dist/cjs/cty-share-sheet.cjs.entry.js +3 -2
- package/dist/cjs/cty-swipe_2.cjs.entry.js +2 -1
- package/dist/cjs/index.cjs.js +3 -2
- package/dist/collection/components/image-viewer/image-viewer.js +1 -1
- package/dist/collection/components/loading/loading.js +1 -1
- package/dist/collection/components/permission-purpose/permission-purpose.js +1 -1
- package/dist/collection/components/record/record.js +1 -1
- package/dist/collection/components/share-sheet/share-sheet.js +3 -2
- package/dist/collection/components/swipe/swipe.js +2 -1
- package/dist/collection/utils/date.js +3 -2
- package/dist/cty-mui/cty-mui.esm.js +1 -1
- package/dist/cty-mui/index.esm.js +1 -1
- package/dist/cty-mui/p-16c44e92.system.js +1 -1
- package/dist/cty-mui/p-3c36f751.entry.js +1 -0
- package/dist/cty-mui/{p-07749e29.system.entry.js → p-45d4316e.system.entry.js} +1 -1
- package/dist/cty-mui/p-57b55051.entry.js +1 -0
- package/dist/cty-mui/p-64f2f4b7.entry.js +1 -0
- package/dist/cty-mui/p-674b0a5c.entry.js +1 -0
- package/dist/cty-mui/{p-42f36ec1.system.entry.js → p-71bba015.system.entry.js} +1 -1
- package/dist/cty-mui/{p-9ccb8585.system.entry.js → p-8cdf32d1.system.entry.js} +1 -1
- package/dist/cty-mui/{p-03f626a3.system.entry.js → p-9faefc79.system.entry.js} +1 -1
- package/dist/cty-mui/{p-6d354b5a.system.js → p-ade47a45.system.js} +1 -1
- package/dist/cty-mui/{p-14b7c1b2.entry.js → p-b11dcc3a.entry.js} +1 -1
- package/dist/cty-mui/{p-a6272e26.system.entry.js → p-c1ada677.system.entry.js} +1 -1
- package/dist/cty-mui/p-c9f962db.entry.js +1 -0
- package/dist/cty-mui/{p-4dd4fb87.system.entry.js → p-cc0069c1.system.entry.js} +1 -1
- package/dist/docs.json +1 -1
- package/dist/esm/cty-image-viewer.entry.js +1 -1
- package/dist/esm/cty-loading.entry.js +1 -1
- package/dist/esm/cty-permission-purpose.entry.js +1 -1
- package/dist/esm/cty-record.entry.js +1 -1
- package/dist/esm/cty-share-sheet.entry.js +3 -2
- package/dist/esm/cty-swipe_2.entry.js +2 -1
- package/dist/esm/index.js +3 -2
- package/dist/esm-es5/cty-image-viewer.entry.js +1 -1
- package/dist/esm-es5/cty-loading.entry.js +1 -1
- package/dist/esm-es5/cty-permission-purpose.entry.js +1 -1
- package/dist/esm-es5/cty-record.entry.js +1 -1
- package/dist/esm-es5/cty-share-sheet.entry.js +1 -1
- package/dist/esm-es5/cty-swipe_2.entry.js +1 -1
- package/dist/esm-es5/index.js +1 -1
- package/package.json +1 -1
- package/dist/cty-mui/p-00e68c05.entry.js +0 -1
- package/dist/cty-mui/p-01fee189.entry.js +0 -1
- package/dist/cty-mui/p-49b7d3e2.entry.js +0 -1
- package/dist/cty-mui/p-e9fb8092.entry.js +0 -1
- package/dist/cty-mui/p-ec4e96fa.entry.js +0 -1
|
@@ -110,7 +110,7 @@ const ImageViewer = /*@__PURE__*/ proxyCustomElement(class ImageViewer extends H
|
|
|
110
110
|
autoplay: false,
|
|
111
111
|
attrs: Object.assign({ zoom }, attrs)
|
|
112
112
|
};
|
|
113
|
-
return (h(Host, { key: 'a5eacd4de8c0126e34364700102aa425723d817b', class: Object.assign(Object.assign({}, getClassMap(this.cssClass)), { 'overlay-hidden cty-pos-cover': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, h("cty-overlay", { key: '31137bb5029a489504b5a29755cbbb9ff1f5c3f4', animated: false, backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, h("div", { key: 'bbee433ec3fe5d78ecda0f8d3115e257cbba5c53', class: "cty-image-viewer" }, h("slot", { key: '58a6ed0579a7a73ac1a54fa02a85f1c9a1690d8c', name: 'start' }), (this.closeable || this.pager || !this.backdropDismiss) && h("div", { key: '
|
|
113
|
+
return (h(Host, { key: 'a5eacd4de8c0126e34364700102aa425723d817b', class: Object.assign(Object.assign({}, getClassMap(this.cssClass)), { 'overlay-hidden cty-pos-cover': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, h("cty-overlay", { key: '31137bb5029a489504b5a29755cbbb9ff1f5c3f4', animated: false, backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, h("div", { key: 'bbee433ec3fe5d78ecda0f8d3115e257cbba5c53', class: "cty-image-viewer" }, h("slot", { key: '58a6ed0579a7a73ac1a54fa02a85f1c9a1690d8c', name: 'start' }), (this.closeable || this.pager || !this.backdropDismiss) && h("div", { key: '6379a57a1b08bb06ba9646dc9e769daabddd0f8d', class: "cty-image-preview__header", onClick: (e) => e.stopPropagation() }, this.pager && h("slot", { key: '007c30e6558490ca06e91b11891e9c7632e52041', name: "pager" }, h("h6", { key: '41431b63e4c1bac59ef6aeafe3150f4658ad59e4', class: "cty-image-preview__pager" }, h("span", { key: 'f8facd872c9a2389ed0ff2e0ec077c252ab5723a', class: "cty-image-preview__index" }, this.activeIndex + 1), " / ", this.images.length)), (this.closeable || !this.backdropDismiss) && h("slot", { key: '5e3469d16e279bc0ee079d1b540f201d16431145', name: "close" }, h("button", { key: '58de0989ec237edad1293ca9dacee1c7164abbc1', class: "cty-image-preview__close cty-button-native", onClick: () => this.dismiss() }, h("cty-icon", { key: '119e52588b171f988fc4314e590c63788b8a0180', name: "cty-close2" })))), h("cty-swiper", Object.assign({ key: 'cb8cab24dee1427bb34ea0303c750cca0d163d3b', ref: (el) => this.swiperEl = el }, swiperAttrs, { onCtySlideChange: (e) => this._slideChange(e) })), h("slot", { key: '21e95c762c2ad48cdb377abc387db67b8cff4a1b', name: 'end' })))));
|
|
114
114
|
}
|
|
115
115
|
get el() { return this; }
|
|
116
116
|
static get watchers() { return {
|
|
@@ -87,7 +87,7 @@ const Loading = /*@__PURE__*/ proxyCustomElement(class Loading extends HTMLEleme
|
|
|
87
87
|
return this.spinnerComponents[this.spinner] || null;
|
|
88
88
|
}
|
|
89
89
|
render() {
|
|
90
|
-
return (h(Host, { key: '66a73b5e98a0eda3e679b122c3f0affd014d61f1', class: Object.assign(Object.assign({}, getClassMap(this.cssClass)), { 'overlay-hidden cty-pos-cover': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, h("cty-overlay", { key: 'ae422786403028566fbf538043cd0b81e8324fee', animated: false, backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, h("div", { key: '
|
|
90
|
+
return (h(Host, { key: '66a73b5e98a0eda3e679b122c3f0affd014d61f1', class: Object.assign(Object.assign({}, getClassMap(this.cssClass)), { 'overlay-hidden cty-pos-cover': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, h("cty-overlay", { key: 'ae422786403028566fbf538043cd0b81e8324fee', animated: false, backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, h("div", { key: '67188c827fe8d804e2fd2b2d68b2e81cae0aedb9', class: this.vertical ? 'cty-loading flex-column-center' : 'cty-loading flex-center', onClick: (e) => e.stopPropagation() }, this.renderSpinner(), h("div", { key: 'b15fe8d1a634fe4d7e6840adfa646fdabd6a351c', class: { 'cty-loading__text': true, 'cty-loading__text-hor': !this.vertical } }, h("slot", { key: 'db63ec434e72a67f9e53e04f5d2256ad31a7e795' }))))));
|
|
91
91
|
}
|
|
92
92
|
get el() { return this; }
|
|
93
93
|
static get watchers() { return {
|
package/components/cty-record.js
CHANGED
|
@@ -427,7 +427,7 @@ const Record = /*@__PURE__*/ proxyCustomElement(class Record extends HTMLElement
|
|
|
427
427
|
}
|
|
428
428
|
}
|
|
429
429
|
render() {
|
|
430
|
-
return (h(Host, { key: 'acd4e6ed523a87db89c1caa066aa7a0f137fb878', class: Object.assign(Object.assign({}, getClassMap(this.cssClass)), { 'overlay-hidden cty-pos-cover': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, h("cty-overlay", { key: 'e3bd92da738fa9ad9c58c5a91e9a8ab40c06dd67', animated: false, position: "bottom", backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, h("div", { key: '
|
|
430
|
+
return (h(Host, { key: 'acd4e6ed523a87db89c1caa066aa7a0f137fb878', class: Object.assign(Object.assign({}, getClassMap(this.cssClass)), { 'overlay-hidden cty-pos-cover': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, h("cty-overlay", { key: 'e3bd92da738fa9ad9c58c5a91e9a8ab40c06dd67', animated: false, position: "bottom", backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, h("div", { key: '436f82a3549e4f728850fab19a46f4202a81248c', class: "cty-record safe-area-bottom-padding flex-center-column", onClick: (e) => e.stopPropagation() }, h("slot", { key: 'f8bded0277caae687f03a9823f0dbbd8663f5312', name: "header" }), this.closeable && (h("div", { key: 'a2dc7e95bc9094eb753d5f30f039d8876d9c6291', class: "cty-record__close", onClick: () => this.handleCloseRecord() }, h("cty-icon", { key: '88107a273d3753926ae31257053c6a8c4b25f895', name: closeOutline }))), h("p", { key: 'c448bbfea8bb172a46f126bab6643880ccaf70ea', class: "cty-record__desc" }, this.recordDescription), h("p", { key: '7b8aa984ef8fd84febcd0b3f3e9fe49ab2b9b177', class: "cty-record__time" }, this.recordDuration), h("div", { key: '6d438aeb90be1badae0b03c3604c36ff5dc3b6bb', class: "cty-record__main flex-align-end-center" }, this.recorded && (h("button", { key: '8cf065897829f664b96337564635d1f9a4d50245', class: "cty-record__redo flex-column-center cty-button-native", onClick: () => this.restartRecording() }, h("cty-icon", { key: '4163eb8e6c3162bf2d8cbee1ef9a979ad6b885aa', name: "cty-redo", class: "flex-center" }), h("span", { key: '3588dccff2ea6ffc419c5023f7129382b586a298' }, "\u91CD\u5F55"))), !this.recording && (h("button", { key: 'a80e4fccb3dd6a49a19262a7e04b7a42cc5727ac', class: "cty-record__button cty-button-native", onClick: () => this.handleRecordAction() }, !this.auditioning && !this.recorded && h("cty-icon", { key: '06420676f43d23230165dd1087589d9fdc87696e', name: "cty-record" }), this.auditioning && this.recorded && h("cty-icon", { key: '6ebc5a1da9ac26687a456ccc842ad4e748869365', name: "cty-pause" }), !this.auditioning && this.recorded && h("cty-icon", { key: '34f9b932c90ca1d450849086671543c541a84c02', name: "cty-play" }))), this.recording && (h("div", { key: 'b9b1ffbff57118c8413269a79302365790a14478', class: "cty-record__recording flex-center", onClick: () => this.stopRecording() }, h("cty-circle", { key: 'd12f239f8fb5c8a19bedb9fa1347982236b78b2b', rate: (this.recordSecond / this.maxSeconds) * 100, width: this.circleWidth, color: this.circleColor }), h("cty-icon", { key: 'ec9ca21f47e06f1a752bc3627dd2d4f1cbbf0c23', name: "cty-pause" }))), this.recorded && (h("button", { key: '174f160b298fdb55dfce0d8ed4100fea6b5b8ee6', class: "cty-record__yes flex-column-center cty-button-native", onClick: () => this.confirmRecording() }, h("cty-icon", { key: '7b684be946a667da56f6ce6418ff5473da9eae49', name: "cty-yes", class: "flex-center" }), h("span", { key: '76fc9093ddde87112bee66390615dbaea310aec4' }, "\u786E\u5B9A")))), !this.auditioning && !this.recorded && !this.recording && h("p", { key: '5f0ba00b4c78b0195a18546ed3f238710850fc0e', class: "cty-record__send" }, "\u4EC5\u53D1\u9001\u8BED\u97F3"), (this.auditioning || this.recorded || this.recording) && h("p", { key: '80710d440f40c86d19b2614e7cf1a6047ed83653', class: "cty-record__status" }, this.recordState))), h("ion-toast", { key: '475343c2e41cb37047ad5ca2cb17d2db0102cf14', isOpen: this.toastOptions.isOpen, message: this.toastOptions.message, duration: 2000, position: "middle", onIonToastWillDismiss: () => (this.toastOptions.isOpen = false) }), this.showWarning && h("cty-alert", { key: '21bf98cfa08a8b20e73723fe548c402e1abf25f8', title: "\u53D6\u6D88\u5F55\u97F3", content: "\u786E\u5B9A\u53D6\u6D88\u672C\u6761\u5F55\u97F3\uFF1F", buttons: ['取消', '确定'], overlayIndex: 1, onCtyTap: e => this.handleAlertAction(e) }, h("button", { key: '67ed092520ab35e155117acb59e17c54c7085bd1', slot: "close", class: "cty--record__alert-close cty-button-native", onClick: () => this.showWarning = false }, h("cty-icon", { key: '90c035f427a704a9071215c5ed22c05d040f5cf7', name: "cty-close2" })))));
|
|
431
431
|
}
|
|
432
432
|
get el() { return this; }
|
|
433
433
|
static get watchers() { return {
|
|
@@ -644,11 +644,12 @@ const ShareSheet = /*@__PURE__*/ proxyCustomElement(class ShareSheet extends HTM
|
|
|
644
644
|
option.handler && option.handler(option);
|
|
645
645
|
this.ctyTap.emit(Object.assign(Object.assign({}, option), { index }));
|
|
646
646
|
}
|
|
647
|
-
_doGuid() {
|
|
647
|
+
_doGuid(e) {
|
|
648
|
+
e.stopPropagation();
|
|
648
649
|
this.ctyGuide.emit();
|
|
649
650
|
}
|
|
650
651
|
render() {
|
|
651
|
-
return (h(Host, { key: '
|
|
652
|
+
return (h(Host, { key: '2d4f5303b0509ca497078dfdc79a7a475d7f12a8', class: Object.assign(Object.assign({}, getClassMap(this.cssClass)), { 'overlay-hidden': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, h("cty-overlay", { key: '568d350443168b4efeda1282a3870f898f1567fe', animated: false, backdropDismiss: this.backdropDismiss, position: "bottom", onCtyDismiss: () => this.dismiss() }, this.guide && this.isMicroMessager && (h("div", { key: '858eda6c20f2dca8cc87aefb367aaea4c3da8bf2', class: "cty-share-guide", onClick: (e) => this._doGuid(e) }, h("img", { key: 'eef370790b12c61e0e716cb76c09eea6329f7ab3', src: this.guideImg }))), h("slot", { key: '14a9e4333047a2f6c10370033f31fffe6b059e95', name: "share-sheet" }), !this.hiddenSheet && (h("div", { key: 'cb5baec3222409ee5a7d3f1a118152224ecf2dba', class: "cty-share-sheet safe-area-bottom-padding", onClick: (e) => e.stopPropagation() }, h("slot", { key: '3149bbf90afb2b740100b97c9333706e0ed4e6fa', name: "header" }), (this.title || this.description) && (h("div", { key: '875e1ee33d044d6cc60967373d1ddfa1fcac1655', class: "cty-share-sheet__header", part: "header" }, this.title && h("cty-divider", { key: '03c0fc17ad784db3b33dacac3d2ae7d90f7fffd7' }, this.title), this.description && h("p", { key: '67f3bb9901816cde3a9aa2c28b20ef5902cbe7d9', class: "cty-share-sheet__description" }, this.description))), h("slot", { key: '9d1c0d6d46d3d4e0e56ab59cd0bd54cf122a4cfe', name: "options" }), h("div", { key: '370aa8fbd0898427fcb7f8cf28572a8b31ea20f8', class: "cty-share-sheet__options flex", part: "options" }, this._options.map((option, idx) => (h("div", { part: "option", class: "cty-share-sheet__option flex-align-center", onClick: () => this._buttonClick(option, idx) }, option.icon && option.icon.indexOf('/') >= 0 && !option.icon.endsWith('.svg') && h("img", { class: "cty-share-sheet__img", src: option.icon }), option.icon && (option.icon.indexOf('/') < 0 || option.icon.endsWith('.svg')) && h("cty-icon", { name: option.icon, class: "cty-share-sheet__icon" }), option.title && h("span", { class: "cty-share-sheet__option-title" }, option.title), option.description && h("span", { class: "cty-share-sheet__option-description" }, option.description))))), h("slot", { key: 'ffdb149c30dd2e87636992c1cf55f29557bacfc9', name: "cancel" }), this.cancelText && (h("button", { key: 'bd84c6782e05f2ef8e5f2b2a98f1ad9ea7fae119', part: "cancel", class: "cty-button-native cty-share-sheet__cancel", onClick: () => this.dismiss() }, this.cancelText))))), this.showPermissionPurpose && h("cty-permission-purpose", { key: '18ea309940a6aa537f8e386636171b1985889485', description: this.permissionDescription }), h("ion-toast", { key: 'a969ab6f939e663c67396e04a8c097f2d4493a19', "is-open": this.isToastOpen, message: this.toastContent, duration: 2000 })));
|
|
652
653
|
}
|
|
653
654
|
get el() { return this; }
|
|
654
655
|
static get watchers() { return {
|
package/components/index.js
CHANGED
|
@@ -13859,7 +13859,7 @@ const defaultTimeZone = {
|
|
|
13859
13859
|
*/
|
|
13860
13860
|
function getUTCDateTime(val, timeZone = '') {
|
|
13861
13861
|
try {
|
|
13862
|
-
// yyyy-MM-
|
|
13862
|
+
// yyyy-MM-ddTHH:mm:ssZ
|
|
13863
13863
|
let curDate = val instanceof Date ? val : convertDate(val);
|
|
13864
13864
|
// 如果传入日期不是当前系统时区的, 需要做转换才能得到正确的UTC时间
|
|
13865
13865
|
if (timeZone) { // 如果目标时间不是当前系统时区时间,需先转换为当前系统时区时间, 否则会不准确
|
|
@@ -13895,7 +13895,8 @@ function getUTCDateTime(val, timeZone = '') {
|
|
|
13895
13895
|
* @returns {string}
|
|
13896
13896
|
*/
|
|
13897
13897
|
function getUTCDate(val) {
|
|
13898
|
-
|
|
13898
|
+
// yyyy-MM-ddZ
|
|
13899
|
+
return (getUTCDateTime(val) || '').split('T')[0];
|
|
13899
13900
|
}
|
|
13900
13901
|
/**
|
|
13901
13902
|
* 获取时区
|
|
@@ -17,7 +17,7 @@ const PermissionPurpose = /*@__PURE__*/ proxyCustomElement(class PermissionPurpo
|
|
|
17
17
|
this.ctyDismiss.emit();
|
|
18
18
|
}
|
|
19
19
|
render() {
|
|
20
|
-
return (h(Host, { key: 'ec59ee269bcf1c9f94fc4aa634cda8df70eab922' }, h("cty-overlay", { key: 'a9e9ea721352a3dac76a3fe82215d81e1e049592', animated: false, backdropDismiss: this.backdropDismiss, position: "top", onCtyDismiss: () => this.dismiss() }, h("div", { key: '
|
|
20
|
+
return (h(Host, { key: 'ec59ee269bcf1c9f94fc4aa634cda8df70eab922' }, h("cty-overlay", { key: 'a9e9ea721352a3dac76a3fe82215d81e1e049592', animated: false, backdropDismiss: this.backdropDismiss, position: "top", onCtyDismiss: () => this.dismiss() }, h("div", { key: 'b847cc13f0e8e75d528a4c57090a5631ce0ab3bf', class: "cty-permission-purpose", onClick: (e) => e.stopPropagation() }, h("div", { key: '4ef9ea197b08570feedaf7422673f442cf77f1fc', innerHTML: sanitizeDOMString(this.description) })))));
|
|
21
21
|
}
|
|
22
22
|
get el() { return this; }
|
|
23
23
|
static get style() { return CtyPermissionPurposeStyle0; }
|
package/components/swipe.js
CHANGED
|
@@ -64,6 +64,7 @@ const Swipe = /*@__PURE__*/ proxyCustomElement(class Swipe extends HTMLElement {
|
|
|
64
64
|
}
|
|
65
65
|
initialize(active = +this.initialSwipe) {
|
|
66
66
|
const cb = () => {
|
|
67
|
+
//可能是版本原因,这里的this.el.offsetParent可能为null,及时加了doubleRaf
|
|
67
68
|
if (!this.el.offsetParent)
|
|
68
69
|
return;
|
|
69
70
|
const children = this.swipeItems = Array.from(this.el.children).filter(child => child.tagName.toLocaleLowerCase() === 'cty-swipe-item');
|
|
@@ -293,7 +294,7 @@ const Swipe = /*@__PURE__*/ proxyCustomElement(class Swipe extends HTMLElement {
|
|
|
293
294
|
'transform': `translate${vertical ? 'Y' : 'X'}(${+offset.toFixed(2)}px)`,
|
|
294
295
|
[vertical ? 'height' : 'width']: `${this.trackSize}px`,
|
|
295
296
|
};
|
|
296
|
-
return (h(Host, { key: '
|
|
297
|
+
return (h(Host, { key: '1e16ecab01f6b5957035a562e9ab43e00a2baff8', class: "cty-swipe" }, h("slot", { key: 'bbfe5d6473bf0393235ebe5871283cbc572ccbb3', name: "start" }), h("div", { key: '96a4d94e5058c8a0be645549d2d9622263d3346a', class: { 'cty-swipe__track': true, 'cty-swipe__track-vertical': this.vertical }, style: style, onTouchStart: (e) => this.onTouchStart(e), onTouchMove: (e) => this.onTouchMove(e), onTouchEnd: (e) => this.onTouchEnd(e), onTouchCancel: (e) => this.onTouchEnd(e), onMouseDown: (e) => this.onTouchStart(e), onMouseMove: (e) => this.onTouchMove(e), onMouseUp: (e) => this.onTouchEnd(e), onMouseLeave: (e) => this.onTouchEnd(e) }, h("slot", { key: 'c7fca3a3ae28d0c8e22e216652f8aaceb3d953b6', onSlotchange: () => this.slotChanged() })), this.renderIndicator(), h("slot", { key: '8f5ebfaf34175e357ec6d21a8295d056a51e0034', name: "end" })));
|
|
297
298
|
}
|
|
298
299
|
get el() { return this; }
|
|
299
300
|
static get style() { return CtySwipeStyle0; }
|
|
@@ -116,7 +116,7 @@ const ImageViewer = class {
|
|
|
116
116
|
autoplay: false,
|
|
117
117
|
attrs: Object.assign({ zoom }, attrs)
|
|
118
118
|
};
|
|
119
|
-
return (index.h(index.Host, { key: 'a5eacd4de8c0126e34364700102aa425723d817b', class: Object.assign(Object.assign({}, theme.getClassMap(this.cssClass)), { 'overlay-hidden cty-pos-cover': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, index.h("cty-overlay", { key: '31137bb5029a489504b5a29755cbbb9ff1f5c3f4', animated: false, backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, index.h("div", { key: 'bbee433ec3fe5d78ecda0f8d3115e257cbba5c53', class: "cty-image-viewer" }, index.h("slot", { key: '58a6ed0579a7a73ac1a54fa02a85f1c9a1690d8c', name: 'start' }), (this.closeable || this.pager || !this.backdropDismiss) && index.h("div", { key: '
|
|
119
|
+
return (index.h(index.Host, { key: 'a5eacd4de8c0126e34364700102aa425723d817b', class: Object.assign(Object.assign({}, theme.getClassMap(this.cssClass)), { 'overlay-hidden cty-pos-cover': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, index.h("cty-overlay", { key: '31137bb5029a489504b5a29755cbbb9ff1f5c3f4', animated: false, backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, index.h("div", { key: 'bbee433ec3fe5d78ecda0f8d3115e257cbba5c53', class: "cty-image-viewer" }, index.h("slot", { key: '58a6ed0579a7a73ac1a54fa02a85f1c9a1690d8c', name: 'start' }), (this.closeable || this.pager || !this.backdropDismiss) && index.h("div", { key: '6379a57a1b08bb06ba9646dc9e769daabddd0f8d', class: "cty-image-preview__header", onClick: (e) => e.stopPropagation() }, this.pager && index.h("slot", { key: '007c30e6558490ca06e91b11891e9c7632e52041', name: "pager" }, index.h("h6", { key: '41431b63e4c1bac59ef6aeafe3150f4658ad59e4', class: "cty-image-preview__pager" }, index.h("span", { key: 'f8facd872c9a2389ed0ff2e0ec077c252ab5723a', class: "cty-image-preview__index" }, this.activeIndex + 1), " / ", this.images.length)), (this.closeable || !this.backdropDismiss) && index.h("slot", { key: '5e3469d16e279bc0ee079d1b540f201d16431145', name: "close" }, index.h("button", { key: '58de0989ec237edad1293ca9dacee1c7164abbc1', class: "cty-image-preview__close cty-button-native", onClick: () => this.dismiss() }, index.h("cty-icon", { key: '119e52588b171f988fc4314e590c63788b8a0180', name: "cty-close2" })))), index.h("cty-swiper", Object.assign({ key: 'cb8cab24dee1427bb34ea0303c750cca0d163d3b', ref: (el) => this.swiperEl = el }, swiperAttrs, { onCtySlideChange: (e) => this._slideChange(e) })), index.h("slot", { key: '21e95c762c2ad48cdb377abc387db67b8cff4a1b', name: 'end' })))));
|
|
120
120
|
}
|
|
121
121
|
get el() { return index.getElement(this); }
|
|
122
122
|
static get watchers() { return {
|
|
@@ -96,7 +96,7 @@ const Loading = class {
|
|
|
96
96
|
return this.spinnerComponents[this.spinner] || null;
|
|
97
97
|
}
|
|
98
98
|
render() {
|
|
99
|
-
return (index.h(index.Host, { key: '66a73b5e98a0eda3e679b122c3f0affd014d61f1', class: Object.assign(Object.assign({}, theme.getClassMap(this.cssClass)), { 'overlay-hidden cty-pos-cover': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, index.h("cty-overlay", { key: 'ae422786403028566fbf538043cd0b81e8324fee', animated: false, backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, index.h("div", { key: '
|
|
99
|
+
return (index.h(index.Host, { key: '66a73b5e98a0eda3e679b122c3f0affd014d61f1', class: Object.assign(Object.assign({}, theme.getClassMap(this.cssClass)), { 'overlay-hidden cty-pos-cover': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, index.h("cty-overlay", { key: 'ae422786403028566fbf538043cd0b81e8324fee', animated: false, backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, index.h("div", { key: '67188c827fe8d804e2fd2b2d68b2e81cae0aedb9', class: this.vertical ? 'cty-loading flex-column-center' : 'cty-loading flex-center', onClick: (e) => e.stopPropagation() }, this.renderSpinner(), index.h("div", { key: 'b15fe8d1a634fe4d7e6840adfa646fdabd6a351c', class: { 'cty-loading__text': true, 'cty-loading__text-hor': !this.vertical } }, index.h("slot", { key: 'db63ec434e72a67f9e53e04f5d2256ad31a7e795' }))))));
|
|
100
100
|
}
|
|
101
101
|
get el() { return index.getElement(this); }
|
|
102
102
|
static get watchers() { return {
|
|
@@ -19,7 +19,7 @@ const PermissionPurpose = class {
|
|
|
19
19
|
this.ctyDismiss.emit();
|
|
20
20
|
}
|
|
21
21
|
render() {
|
|
22
|
-
return (index.h(index.Host, { key: 'ec59ee269bcf1c9f94fc4aa634cda8df70eab922' }, index.h("cty-overlay", { key: 'a9e9ea721352a3dac76a3fe82215d81e1e049592', animated: false, backdropDismiss: this.backdropDismiss, position: "top", onCtyDismiss: () => this.dismiss() }, index.h("div", { key: '
|
|
22
|
+
return (index.h(index.Host, { key: 'ec59ee269bcf1c9f94fc4aa634cda8df70eab922' }, index.h("cty-overlay", { key: 'a9e9ea721352a3dac76a3fe82215d81e1e049592', animated: false, backdropDismiss: this.backdropDismiss, position: "top", onCtyDismiss: () => this.dismiss() }, index.h("div", { key: 'b847cc13f0e8e75d528a4c57090a5631ce0ab3bf', class: "cty-permission-purpose", onClick: (e) => e.stopPropagation() }, index.h("div", { key: '4ef9ea197b08570feedaf7422673f442cf77f1fc', innerHTML: index$1.sanitizeDOMString(this.description) })))));
|
|
23
23
|
}
|
|
24
24
|
get el() { return index.getElement(this); }
|
|
25
25
|
};
|
|
@@ -432,7 +432,7 @@ const Record = class {
|
|
|
432
432
|
}
|
|
433
433
|
}
|
|
434
434
|
render() {
|
|
435
|
-
return (index.h(index.Host, { key: 'acd4e6ed523a87db89c1caa066aa7a0f137fb878', class: Object.assign(Object.assign({}, theme.getClassMap(this.cssClass)), { 'overlay-hidden cty-pos-cover': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, index.h("cty-overlay", { key: 'e3bd92da738fa9ad9c58c5a91e9a8ab40c06dd67', animated: false, position: "bottom", backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, index.h("div", { key: '
|
|
435
|
+
return (index.h(index.Host, { key: 'acd4e6ed523a87db89c1caa066aa7a0f137fb878', class: Object.assign(Object.assign({}, theme.getClassMap(this.cssClass)), { 'overlay-hidden cty-pos-cover': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, index.h("cty-overlay", { key: 'e3bd92da738fa9ad9c58c5a91e9a8ab40c06dd67', animated: false, position: "bottom", backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, index.h("div", { key: '436f82a3549e4f728850fab19a46f4202a81248c', class: "cty-record safe-area-bottom-padding flex-center-column", onClick: (e) => e.stopPropagation() }, index.h("slot", { key: 'f8bded0277caae687f03a9823f0dbbd8663f5312', name: "header" }), this.closeable && (index.h("div", { key: 'a2dc7e95bc9094eb753d5f30f039d8876d9c6291', class: "cty-record__close", onClick: () => this.handleCloseRecord() }, index.h("cty-icon", { key: '88107a273d3753926ae31257053c6a8c4b25f895', name: index$1.closeOutline }))), index.h("p", { key: 'c448bbfea8bb172a46f126bab6643880ccaf70ea', class: "cty-record__desc" }, this.recordDescription), index.h("p", { key: '7b8aa984ef8fd84febcd0b3f3e9fe49ab2b9b177', class: "cty-record__time" }, this.recordDuration), index.h("div", { key: '6d438aeb90be1badae0b03c3604c36ff5dc3b6bb', class: "cty-record__main flex-align-end-center" }, this.recorded && (index.h("button", { key: '8cf065897829f664b96337564635d1f9a4d50245', class: "cty-record__redo flex-column-center cty-button-native", onClick: () => this.restartRecording() }, index.h("cty-icon", { key: '4163eb8e6c3162bf2d8cbee1ef9a979ad6b885aa', name: "cty-redo", class: "flex-center" }), index.h("span", { key: '3588dccff2ea6ffc419c5023f7129382b586a298' }, "\u91CD\u5F55"))), !this.recording && (index.h("button", { key: 'a80e4fccb3dd6a49a19262a7e04b7a42cc5727ac', class: "cty-record__button cty-button-native", onClick: () => this.handleRecordAction() }, !this.auditioning && !this.recorded && index.h("cty-icon", { key: '06420676f43d23230165dd1087589d9fdc87696e', name: "cty-record" }), this.auditioning && this.recorded && index.h("cty-icon", { key: '6ebc5a1da9ac26687a456ccc842ad4e748869365', name: "cty-pause" }), !this.auditioning && this.recorded && index.h("cty-icon", { key: '34f9b932c90ca1d450849086671543c541a84c02', name: "cty-play" }))), this.recording && (index.h("div", { key: 'b9b1ffbff57118c8413269a79302365790a14478', class: "cty-record__recording flex-center", onClick: () => this.stopRecording() }, index.h("cty-circle", { key: 'd12f239f8fb5c8a19bedb9fa1347982236b78b2b', rate: (this.recordSecond / this.maxSeconds) * 100, width: this.circleWidth, color: this.circleColor }), index.h("cty-icon", { key: 'ec9ca21f47e06f1a752bc3627dd2d4f1cbbf0c23', name: "cty-pause" }))), this.recorded && (index.h("button", { key: '174f160b298fdb55dfce0d8ed4100fea6b5b8ee6', class: "cty-record__yes flex-column-center cty-button-native", onClick: () => this.confirmRecording() }, index.h("cty-icon", { key: '7b684be946a667da56f6ce6418ff5473da9eae49', name: "cty-yes", class: "flex-center" }), index.h("span", { key: '76fc9093ddde87112bee66390615dbaea310aec4' }, "\u786E\u5B9A")))), !this.auditioning && !this.recorded && !this.recording && index.h("p", { key: '5f0ba00b4c78b0195a18546ed3f238710850fc0e', class: "cty-record__send" }, "\u4EC5\u53D1\u9001\u8BED\u97F3"), (this.auditioning || this.recorded || this.recording) && index.h("p", { key: '80710d440f40c86d19b2614e7cf1a6047ed83653', class: "cty-record__status" }, this.recordState))), index.h("ion-toast", { key: '475343c2e41cb37047ad5ca2cb17d2db0102cf14', isOpen: this.toastOptions.isOpen, message: this.toastOptions.message, duration: 2000, position: "middle", onIonToastWillDismiss: () => (this.toastOptions.isOpen = false) }), this.showWarning && index.h("cty-alert", { key: '21bf98cfa08a8b20e73723fe548c402e1abf25f8', title: "\u53D6\u6D88\u5F55\u97F3", content: "\u786E\u5B9A\u53D6\u6D88\u672C\u6761\u5F55\u97F3\uFF1F", buttons: ['取消', '确定'], overlayIndex: 1, onCtyTap: e => this.handleAlertAction(e) }, index.h("button", { key: '67ed092520ab35e155117acb59e17c54c7085bd1', slot: "close", class: "cty--record__alert-close cty-button-native", onClick: () => this.showWarning = false }, index.h("cty-icon", { key: '90c035f427a704a9071215c5ed22c05d040f5cf7', name: "cty-close2" })))));
|
|
436
436
|
}
|
|
437
437
|
get el() { return index.getElement(this); }
|
|
438
438
|
static get watchers() { return {
|
|
@@ -648,11 +648,12 @@ const ShareSheet = class {
|
|
|
648
648
|
option.handler && option.handler(option);
|
|
649
649
|
this.ctyTap.emit(Object.assign(Object.assign({}, option), { index }));
|
|
650
650
|
}
|
|
651
|
-
_doGuid() {
|
|
651
|
+
_doGuid(e) {
|
|
652
|
+
e.stopPropagation();
|
|
652
653
|
this.ctyGuide.emit();
|
|
653
654
|
}
|
|
654
655
|
render() {
|
|
655
|
-
return (index.h(index.Host, { key: '
|
|
656
|
+
return (index.h(index.Host, { key: '2d4f5303b0509ca497078dfdc79a7a475d7f12a8', class: Object.assign(Object.assign({}, theme.getClassMap(this.cssClass)), { 'overlay-hidden': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, index.h("cty-overlay", { key: '568d350443168b4efeda1282a3870f898f1567fe', animated: false, backdropDismiss: this.backdropDismiss, position: "bottom", onCtyDismiss: () => this.dismiss() }, this.guide && this.isMicroMessager && (index.h("div", { key: '858eda6c20f2dca8cc87aefb367aaea4c3da8bf2', class: "cty-share-guide", onClick: (e) => this._doGuid(e) }, index.h("img", { key: 'eef370790b12c61e0e716cb76c09eea6329f7ab3', src: this.guideImg }))), index.h("slot", { key: '14a9e4333047a2f6c10370033f31fffe6b059e95', name: "share-sheet" }), !this.hiddenSheet && (index.h("div", { key: 'cb5baec3222409ee5a7d3f1a118152224ecf2dba', class: "cty-share-sheet safe-area-bottom-padding", onClick: (e) => e.stopPropagation() }, index.h("slot", { key: '3149bbf90afb2b740100b97c9333706e0ed4e6fa', name: "header" }), (this.title || this.description) && (index.h("div", { key: '875e1ee33d044d6cc60967373d1ddfa1fcac1655', class: "cty-share-sheet__header", part: "header" }, this.title && index.h("cty-divider", { key: '03c0fc17ad784db3b33dacac3d2ae7d90f7fffd7' }, this.title), this.description && index.h("p", { key: '67f3bb9901816cde3a9aa2c28b20ef5902cbe7d9', class: "cty-share-sheet__description" }, this.description))), index.h("slot", { key: '9d1c0d6d46d3d4e0e56ab59cd0bd54cf122a4cfe', name: "options" }), index.h("div", { key: '370aa8fbd0898427fcb7f8cf28572a8b31ea20f8', class: "cty-share-sheet__options flex", part: "options" }, this._options.map((option, idx) => (index.h("div", { part: "option", class: "cty-share-sheet__option flex-align-center", onClick: () => this._buttonClick(option, idx) }, option.icon && option.icon.indexOf('/') >= 0 && !option.icon.endsWith('.svg') && index.h("img", { class: "cty-share-sheet__img", src: option.icon }), option.icon && (option.icon.indexOf('/') < 0 || option.icon.endsWith('.svg')) && index.h("cty-icon", { name: option.icon, class: "cty-share-sheet__icon" }), option.title && index.h("span", { class: "cty-share-sheet__option-title" }, option.title), option.description && index.h("span", { class: "cty-share-sheet__option-description" }, option.description))))), index.h("slot", { key: 'ffdb149c30dd2e87636992c1cf55f29557bacfc9', name: "cancel" }), this.cancelText && (index.h("button", { key: 'bd84c6782e05f2ef8e5f2b2a98f1ad9ea7fae119', part: "cancel", class: "cty-button-native cty-share-sheet__cancel", onClick: () => this.dismiss() }, this.cancelText))))), this.showPermissionPurpose && index.h("cty-permission-purpose", { key: '18ea309940a6aa537f8e386636171b1985889485', description: this.permissionDescription }), index.h("ion-toast", { key: 'a969ab6f939e663c67396e04a8c097f2d4493a19', "is-open": this.isToastOpen, message: this.toastContent, duration: 2000 })));
|
|
656
657
|
}
|
|
657
658
|
get el() { return index.getElement(this); }
|
|
658
659
|
static get watchers() { return {
|
|
@@ -66,6 +66,7 @@ const Swipe = class {
|
|
|
66
66
|
}
|
|
67
67
|
initialize(active = +this.initialSwipe) {
|
|
68
68
|
const cb = () => {
|
|
69
|
+
//可能是版本原因,这里的this.el.offsetParent可能为null,及时加了doubleRaf
|
|
69
70
|
if (!this.el.offsetParent)
|
|
70
71
|
return;
|
|
71
72
|
const children = this.swipeItems = Array.from(this.el.children).filter(child => child.tagName.toLocaleLowerCase() === 'cty-swipe-item');
|
|
@@ -295,7 +296,7 @@ const Swipe = class {
|
|
|
295
296
|
'transform': `translate${vertical ? 'Y' : 'X'}(${+offset.toFixed(2)}px)`,
|
|
296
297
|
[vertical ? 'height' : 'width']: `${this.trackSize}px`,
|
|
297
298
|
};
|
|
298
|
-
return (index.h(index.Host, { key: '
|
|
299
|
+
return (index.h(index.Host, { key: '1e16ecab01f6b5957035a562e9ab43e00a2baff8', class: "cty-swipe" }, index.h("slot", { key: 'bbfe5d6473bf0393235ebe5871283cbc572ccbb3', name: "start" }), index.h("div", { key: '96a4d94e5058c8a0be645549d2d9622263d3346a', class: { 'cty-swipe__track': true, 'cty-swipe__track-vertical': this.vertical }, style: style, onTouchStart: (e) => this.onTouchStart(e), onTouchMove: (e) => this.onTouchMove(e), onTouchEnd: (e) => this.onTouchEnd(e), onTouchCancel: (e) => this.onTouchEnd(e), onMouseDown: (e) => this.onTouchStart(e), onMouseMove: (e) => this.onTouchMove(e), onMouseUp: (e) => this.onTouchEnd(e), onMouseLeave: (e) => this.onTouchEnd(e) }, index.h("slot", { key: 'c7fca3a3ae28d0c8e22e216652f8aaceb3d953b6', onSlotchange: () => this.slotChanged() })), this.renderIndicator(), index.h("slot", { key: '8f5ebfaf34175e357ec6d21a8295d056a51e0034', name: "end" })));
|
|
299
300
|
}
|
|
300
301
|
get el() { return index.getElement(this); }
|
|
301
302
|
};
|
package/dist/cjs/index.cjs.js
CHANGED
|
@@ -13863,7 +13863,7 @@ const defaultTimeZone = {
|
|
|
13863
13863
|
*/
|
|
13864
13864
|
function getUTCDateTime(val, timeZone = '') {
|
|
13865
13865
|
try {
|
|
13866
|
-
// yyyy-MM-
|
|
13866
|
+
// yyyy-MM-ddTHH:mm:ssZ
|
|
13867
13867
|
let curDate = val instanceof Date ? val : convertDate(val);
|
|
13868
13868
|
// 如果传入日期不是当前系统时区的, 需要做转换才能得到正确的UTC时间
|
|
13869
13869
|
if (timeZone) { // 如果目标时间不是当前系统时区时间,需先转换为当前系统时区时间, 否则会不准确
|
|
@@ -13899,7 +13899,8 @@ function getUTCDateTime(val, timeZone = '') {
|
|
|
13899
13899
|
* @returns {string}
|
|
13900
13900
|
*/
|
|
13901
13901
|
function getUTCDate(val) {
|
|
13902
|
-
|
|
13902
|
+
// yyyy-MM-ddZ
|
|
13903
|
+
return (getUTCDateTime(val) || '').split('T')[0];
|
|
13903
13904
|
}
|
|
13904
13905
|
/**
|
|
13905
13906
|
* 获取时区
|
|
@@ -97,7 +97,7 @@ export class ImageViewer {
|
|
|
97
97
|
autoplay: false,
|
|
98
98
|
attrs: Object.assign({ zoom }, attrs)
|
|
99
99
|
};
|
|
100
|
-
return (h(Host, { key: 'a5eacd4de8c0126e34364700102aa425723d817b', class: Object.assign(Object.assign({}, getClassMap(this.cssClass)), { 'overlay-hidden cty-pos-cover': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, h("cty-overlay", { key: '31137bb5029a489504b5a29755cbbb9ff1f5c3f4', animated: false, backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, h("div", { key: 'bbee433ec3fe5d78ecda0f8d3115e257cbba5c53', class: "cty-image-viewer" }, h("slot", { key: '58a6ed0579a7a73ac1a54fa02a85f1c9a1690d8c', name: 'start' }), (this.closeable || this.pager || !this.backdropDismiss) && h("div", { key: '
|
|
100
|
+
return (h(Host, { key: 'a5eacd4de8c0126e34364700102aa425723d817b', class: Object.assign(Object.assign({}, getClassMap(this.cssClass)), { 'overlay-hidden cty-pos-cover': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, h("cty-overlay", { key: '31137bb5029a489504b5a29755cbbb9ff1f5c3f4', animated: false, backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, h("div", { key: 'bbee433ec3fe5d78ecda0f8d3115e257cbba5c53', class: "cty-image-viewer" }, h("slot", { key: '58a6ed0579a7a73ac1a54fa02a85f1c9a1690d8c', name: 'start' }), (this.closeable || this.pager || !this.backdropDismiss) && h("div", { key: '6379a57a1b08bb06ba9646dc9e769daabddd0f8d', class: "cty-image-preview__header", onClick: (e) => e.stopPropagation() }, this.pager && h("slot", { key: '007c30e6558490ca06e91b11891e9c7632e52041', name: "pager" }, h("h6", { key: '41431b63e4c1bac59ef6aeafe3150f4658ad59e4', class: "cty-image-preview__pager" }, h("span", { key: 'f8facd872c9a2389ed0ff2e0ec077c252ab5723a', class: "cty-image-preview__index" }, this.activeIndex + 1), " / ", this.images.length)), (this.closeable || !this.backdropDismiss) && h("slot", { key: '5e3469d16e279bc0ee079d1b540f201d16431145', name: "close" }, h("button", { key: '58de0989ec237edad1293ca9dacee1c7164abbc1', class: "cty-image-preview__close cty-button-native", onClick: () => this.dismiss() }, h("cty-icon", { key: '119e52588b171f988fc4314e590c63788b8a0180', name: "cty-close2" })))), h("cty-swiper", Object.assign({ key: 'cb8cab24dee1427bb34ea0303c750cca0d163d3b', ref: (el) => this.swiperEl = el }, swiperAttrs, { onCtySlideChange: (e) => this._slideChange(e) })), h("slot", { key: '21e95c762c2ad48cdb377abc387db67b8cff4a1b', name: 'end' })))));
|
|
101
101
|
}
|
|
102
102
|
static get is() { return "cty-image-viewer"; }
|
|
103
103
|
static get encapsulation() { return "shadow"; }
|
|
@@ -78,7 +78,7 @@ export class Loading {
|
|
|
78
78
|
return this.spinnerComponents[this.spinner] || null;
|
|
79
79
|
}
|
|
80
80
|
render() {
|
|
81
|
-
return (h(Host, { key: '66a73b5e98a0eda3e679b122c3f0affd014d61f1', class: Object.assign(Object.assign({}, getClassMap(this.cssClass)), { 'overlay-hidden cty-pos-cover': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, h("cty-overlay", { key: 'ae422786403028566fbf538043cd0b81e8324fee', animated: false, backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, h("div", { key: '
|
|
81
|
+
return (h(Host, { key: '66a73b5e98a0eda3e679b122c3f0affd014d61f1', class: Object.assign(Object.assign({}, getClassMap(this.cssClass)), { 'overlay-hidden cty-pos-cover': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, h("cty-overlay", { key: 'ae422786403028566fbf538043cd0b81e8324fee', animated: false, backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, h("div", { key: '67188c827fe8d804e2fd2b2d68b2e81cae0aedb9', class: this.vertical ? 'cty-loading flex-column-center' : 'cty-loading flex-center', onClick: (e) => e.stopPropagation() }, this.renderSpinner(), h("div", { key: 'b15fe8d1a634fe4d7e6840adfa646fdabd6a351c', class: { 'cty-loading__text': true, 'cty-loading__text-hor': !this.vertical } }, h("slot", { key: 'db63ec434e72a67f9e53e04f5d2256ad31a7e795' }))))));
|
|
82
82
|
}
|
|
83
83
|
static get is() { return "cty-loading"; }
|
|
84
84
|
static get encapsulation() { return "shadow"; }
|
|
@@ -9,7 +9,7 @@ export class PermissionPurpose {
|
|
|
9
9
|
this.ctyDismiss.emit();
|
|
10
10
|
}
|
|
11
11
|
render() {
|
|
12
|
-
return (h(Host, { key: 'ec59ee269bcf1c9f94fc4aa634cda8df70eab922' }, h("cty-overlay", { key: 'a9e9ea721352a3dac76a3fe82215d81e1e049592', animated: false, backdropDismiss: this.backdropDismiss, position: "top", onCtyDismiss: () => this.dismiss() }, h("div", { key: '
|
|
12
|
+
return (h(Host, { key: 'ec59ee269bcf1c9f94fc4aa634cda8df70eab922' }, h("cty-overlay", { key: 'a9e9ea721352a3dac76a3fe82215d81e1e049592', animated: false, backdropDismiss: this.backdropDismiss, position: "top", onCtyDismiss: () => this.dismiss() }, h("div", { key: 'b847cc13f0e8e75d528a4c57090a5631ce0ab3bf', class: "cty-permission-purpose", onClick: (e) => e.stopPropagation() }, h("div", { key: '4ef9ea197b08570feedaf7422673f442cf77f1fc', innerHTML: sanitizeDOMString(this.description) })))));
|
|
13
13
|
}
|
|
14
14
|
static get is() { return "cty-permission-purpose"; }
|
|
15
15
|
static get encapsulation() { return "shadow"; }
|
|
@@ -229,7 +229,7 @@ export class Record {
|
|
|
229
229
|
}
|
|
230
230
|
}
|
|
231
231
|
render() {
|
|
232
|
-
return (h(Host, { key: 'acd4e6ed523a87db89c1caa066aa7a0f137fb878', class: Object.assign(Object.assign({}, getClassMap(this.cssClass)), { 'overlay-hidden cty-pos-cover': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, h("cty-overlay", { key: 'e3bd92da738fa9ad9c58c5a91e9a8ab40c06dd67', animated: false, position: "bottom", backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, h("div", { key: '
|
|
232
|
+
return (h(Host, { key: 'acd4e6ed523a87db89c1caa066aa7a0f137fb878', class: Object.assign(Object.assign({}, getClassMap(this.cssClass)), { 'overlay-hidden cty-pos-cover': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, h("cty-overlay", { key: 'e3bd92da738fa9ad9c58c5a91e9a8ab40c06dd67', animated: false, position: "bottom", backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, h("div", { key: '436f82a3549e4f728850fab19a46f4202a81248c', class: "cty-record safe-area-bottom-padding flex-center-column", onClick: (e) => e.stopPropagation() }, h("slot", { key: 'f8bded0277caae687f03a9823f0dbbd8663f5312', name: "header" }), this.closeable && (h("div", { key: 'a2dc7e95bc9094eb753d5f30f039d8876d9c6291', class: "cty-record__close", onClick: () => this.handleCloseRecord() }, h("cty-icon", { key: '88107a273d3753926ae31257053c6a8c4b25f895', name: closeOutline }))), h("p", { key: 'c448bbfea8bb172a46f126bab6643880ccaf70ea', class: "cty-record__desc" }, this.recordDescription), h("p", { key: '7b8aa984ef8fd84febcd0b3f3e9fe49ab2b9b177', class: "cty-record__time" }, this.recordDuration), h("div", { key: '6d438aeb90be1badae0b03c3604c36ff5dc3b6bb', class: "cty-record__main flex-align-end-center" }, this.recorded && (h("button", { key: '8cf065897829f664b96337564635d1f9a4d50245', class: "cty-record__redo flex-column-center cty-button-native", onClick: () => this.restartRecording() }, h("cty-icon", { key: '4163eb8e6c3162bf2d8cbee1ef9a979ad6b885aa', name: "cty-redo", class: "flex-center" }), h("span", { key: '3588dccff2ea6ffc419c5023f7129382b586a298' }, "\u91CD\u5F55"))), !this.recording && (h("button", { key: 'a80e4fccb3dd6a49a19262a7e04b7a42cc5727ac', class: "cty-record__button cty-button-native", onClick: () => this.handleRecordAction() }, !this.auditioning && !this.recorded && h("cty-icon", { key: '06420676f43d23230165dd1087589d9fdc87696e', name: "cty-record" }), this.auditioning && this.recorded && h("cty-icon", { key: '6ebc5a1da9ac26687a456ccc842ad4e748869365', name: "cty-pause" }), !this.auditioning && this.recorded && h("cty-icon", { key: '34f9b932c90ca1d450849086671543c541a84c02', name: "cty-play" }))), this.recording && (h("div", { key: 'b9b1ffbff57118c8413269a79302365790a14478', class: "cty-record__recording flex-center", onClick: () => this.stopRecording() }, h("cty-circle", { key: 'd12f239f8fb5c8a19bedb9fa1347982236b78b2b', rate: (this.recordSecond / this.maxSeconds) * 100, width: this.circleWidth, color: this.circleColor }), h("cty-icon", { key: 'ec9ca21f47e06f1a752bc3627dd2d4f1cbbf0c23', name: "cty-pause" }))), this.recorded && (h("button", { key: '174f160b298fdb55dfce0d8ed4100fea6b5b8ee6', class: "cty-record__yes flex-column-center cty-button-native", onClick: () => this.confirmRecording() }, h("cty-icon", { key: '7b684be946a667da56f6ce6418ff5473da9eae49', name: "cty-yes", class: "flex-center" }), h("span", { key: '76fc9093ddde87112bee66390615dbaea310aec4' }, "\u786E\u5B9A")))), !this.auditioning && !this.recorded && !this.recording && h("p", { key: '5f0ba00b4c78b0195a18546ed3f238710850fc0e', class: "cty-record__send" }, "\u4EC5\u53D1\u9001\u8BED\u97F3"), (this.auditioning || this.recorded || this.recording) && h("p", { key: '80710d440f40c86d19b2614e7cf1a6047ed83653', class: "cty-record__status" }, this.recordState))), h("ion-toast", { key: '475343c2e41cb37047ad5ca2cb17d2db0102cf14', isOpen: this.toastOptions.isOpen, message: this.toastOptions.message, duration: 2000, position: "middle", onIonToastWillDismiss: () => (this.toastOptions.isOpen = false) }), this.showWarning && h("cty-alert", { key: '21bf98cfa08a8b20e73723fe548c402e1abf25f8', title: "\u53D6\u6D88\u5F55\u97F3", content: "\u786E\u5B9A\u53D6\u6D88\u672C\u6761\u5F55\u97F3\uFF1F", buttons: ['取消', '确定'], overlayIndex: 1, onCtyTap: e => this.handleAlertAction(e) }, h("button", { key: '67ed092520ab35e155117acb59e17c54c7085bd1', slot: "close", class: "cty--record__alert-close cty-button-native", onClick: () => this.showWarning = false }, h("cty-icon", { key: '90c035f427a704a9071215c5ed22c05d040f5cf7', name: "cty-close2" })))));
|
|
233
233
|
}
|
|
234
234
|
static get is() { return "cty-record"; }
|
|
235
235
|
static get encapsulation() { return "shadow"; }
|
|
@@ -377,11 +377,12 @@ export class ShareSheet {
|
|
|
377
377
|
option.handler && option.handler(option);
|
|
378
378
|
this.ctyTap.emit(Object.assign(Object.assign({}, option), { index }));
|
|
379
379
|
}
|
|
380
|
-
_doGuid() {
|
|
380
|
+
_doGuid(e) {
|
|
381
|
+
e.stopPropagation();
|
|
381
382
|
this.ctyGuide.emit();
|
|
382
383
|
}
|
|
383
384
|
render() {
|
|
384
|
-
return (h(Host, { key: '
|
|
385
|
+
return (h(Host, { key: '2d4f5303b0509ca497078dfdc79a7a475d7f12a8', class: Object.assign(Object.assign({}, getClassMap(this.cssClass)), { 'overlay-hidden': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, h("cty-overlay", { key: '568d350443168b4efeda1282a3870f898f1567fe', animated: false, backdropDismiss: this.backdropDismiss, position: "bottom", onCtyDismiss: () => this.dismiss() }, this.guide && this.isMicroMessager && (h("div", { key: '858eda6c20f2dca8cc87aefb367aaea4c3da8bf2', class: "cty-share-guide", onClick: (e) => this._doGuid(e) }, h("img", { key: 'eef370790b12c61e0e716cb76c09eea6329f7ab3', src: this.guideImg }))), h("slot", { key: '14a9e4333047a2f6c10370033f31fffe6b059e95', name: "share-sheet" }), !this.hiddenSheet && (h("div", { key: 'cb5baec3222409ee5a7d3f1a118152224ecf2dba', class: "cty-share-sheet safe-area-bottom-padding", onClick: (e) => e.stopPropagation() }, h("slot", { key: '3149bbf90afb2b740100b97c9333706e0ed4e6fa', name: "header" }), (this.title || this.description) && (h("div", { key: '875e1ee33d044d6cc60967373d1ddfa1fcac1655', class: "cty-share-sheet__header", part: "header" }, this.title && h("cty-divider", { key: '03c0fc17ad784db3b33dacac3d2ae7d90f7fffd7' }, this.title), this.description && h("p", { key: '67f3bb9901816cde3a9aa2c28b20ef5902cbe7d9', class: "cty-share-sheet__description" }, this.description))), h("slot", { key: '9d1c0d6d46d3d4e0e56ab59cd0bd54cf122a4cfe', name: "options" }), h("div", { key: '370aa8fbd0898427fcb7f8cf28572a8b31ea20f8', class: "cty-share-sheet__options flex", part: "options" }, this._options.map((option, idx) => (h("div", { part: "option", class: "cty-share-sheet__option flex-align-center", onClick: () => this._buttonClick(option, idx) }, option.icon && option.icon.indexOf('/') >= 0 && !option.icon.endsWith('.svg') && h("img", { class: "cty-share-sheet__img", src: option.icon }), option.icon && (option.icon.indexOf('/') < 0 || option.icon.endsWith('.svg')) && h("cty-icon", { name: option.icon, class: "cty-share-sheet__icon" }), option.title && h("span", { class: "cty-share-sheet__option-title" }, option.title), option.description && h("span", { class: "cty-share-sheet__option-description" }, option.description))))), h("slot", { key: 'ffdb149c30dd2e87636992c1cf55f29557bacfc9', name: "cancel" }), this.cancelText && (h("button", { key: 'bd84c6782e05f2ef8e5f2b2a98f1ad9ea7fae119', part: "cancel", class: "cty-button-native cty-share-sheet__cancel", onClick: () => this.dismiss() }, this.cancelText))))), this.showPermissionPurpose && h("cty-permission-purpose", { key: '18ea309940a6aa537f8e386636171b1985889485', description: this.permissionDescription }), h("ion-toast", { key: 'a969ab6f939e663c67396e04a8c097f2d4493a19', "is-open": this.isToastOpen, message: this.toastContent, duration: 2000 })));
|
|
385
386
|
}
|
|
386
387
|
static get is() { return "cty-share-sheet"; }
|
|
387
388
|
static get encapsulation() { return "shadow"; }
|
|
@@ -54,6 +54,7 @@ export class Swipe {
|
|
|
54
54
|
}
|
|
55
55
|
initialize(active = +this.initialSwipe) {
|
|
56
56
|
const cb = () => {
|
|
57
|
+
//可能是版本原因,这里的this.el.offsetParent可能为null,及时加了doubleRaf
|
|
57
58
|
if (!this.el.offsetParent)
|
|
58
59
|
return;
|
|
59
60
|
const children = this.swipeItems = Array.from(this.el.children).filter(child => child.tagName.toLocaleLowerCase() === 'cty-swipe-item');
|
|
@@ -283,7 +284,7 @@ export class Swipe {
|
|
|
283
284
|
'transform': `translate${vertical ? 'Y' : 'X'}(${+offset.toFixed(2)}px)`,
|
|
284
285
|
[vertical ? 'height' : 'width']: `${this.trackSize}px`,
|
|
285
286
|
};
|
|
286
|
-
return (h(Host, { key: '
|
|
287
|
+
return (h(Host, { key: '1e16ecab01f6b5957035a562e9ab43e00a2baff8', class: "cty-swipe" }, h("slot", { key: 'bbfe5d6473bf0393235ebe5871283cbc572ccbb3', name: "start" }), h("div", { key: '96a4d94e5058c8a0be645549d2d9622263d3346a', class: { 'cty-swipe__track': true, 'cty-swipe__track-vertical': this.vertical }, style: style, onTouchStart: (e) => this.onTouchStart(e), onTouchMove: (e) => this.onTouchMove(e), onTouchEnd: (e) => this.onTouchEnd(e), onTouchCancel: (e) => this.onTouchEnd(e), onMouseDown: (e) => this.onTouchStart(e), onMouseMove: (e) => this.onTouchMove(e), onMouseUp: (e) => this.onTouchEnd(e), onMouseLeave: (e) => this.onTouchEnd(e) }, h("slot", { key: 'c7fca3a3ae28d0c8e22e216652f8aaceb3d953b6', onSlotchange: () => this.slotChanged() })), this.renderIndicator(), h("slot", { key: '8f5ebfaf34175e357ec6d21a8295d056a51e0034', name: "end" })));
|
|
287
288
|
}
|
|
288
289
|
static get is() { return "cty-swipe"; }
|
|
289
290
|
static get encapsulation() { return "shadow"; }
|
|
@@ -42,7 +42,7 @@ const defaultTimeZone = {
|
|
|
42
42
|
*/
|
|
43
43
|
export function getUTCDateTime(val, timeZone = '') {
|
|
44
44
|
try {
|
|
45
|
-
// yyyy-MM-
|
|
45
|
+
// yyyy-MM-ddTHH:mm:ssZ
|
|
46
46
|
let curDate = val instanceof Date ? val : convertDate(val);
|
|
47
47
|
// 如果传入日期不是当前系统时区的, 需要做转换才能得到正确的UTC时间
|
|
48
48
|
if (timeZone) { // 如果目标时间不是当前系统时区时间,需先转换为当前系统时区时间, 否则会不准确
|
|
@@ -78,7 +78,8 @@ export function getUTCDateTime(val, timeZone = '') {
|
|
|
78
78
|
* @returns {string}
|
|
79
79
|
*/
|
|
80
80
|
export function getUTCDate(val) {
|
|
81
|
-
|
|
81
|
+
// yyyy-MM-ddZ
|
|
82
|
+
return (getUTCDateTime(val) || '').split('T')[0];
|
|
82
83
|
}
|
|
83
84
|
/**
|
|
84
85
|
* 获取时区
|