cty-mui-core 1.0.5 → 1.0.6
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/crop-image.js +2 -2
- package/components/cty-action-sheet.d.ts +1 -1
- package/components/cty-agree.d.ts +1 -1
- package/components/cty-alert.d.ts +1 -1
- package/components/cty-answer-sheet.d.ts +1 -1
- package/components/cty-article-card.d.ts +1 -1
- package/components/cty-audio.d.ts +1 -1
- package/components/cty-banner.d.ts +1 -1
- package/components/cty-camera-photo.d.ts +1 -1
- package/components/cty-camera-photo.js +5 -3
- package/components/cty-canvas-board.d.ts +1 -1
- package/components/cty-canvas-video.d.ts +1 -1
- package/components/cty-cascader.d.ts +1 -1
- package/components/cty-cascader.js +66 -29
- package/components/cty-circle.d.ts +1 -1
- package/components/cty-count-down.d.ts +1 -1
- package/components/cty-crop-image.d.ts +1 -1
- package/components/cty-divider.d.ts +1 -1
- package/components/cty-empty.d.ts +1 -1
- package/components/cty-floating-bubble.d.ts +1 -1
- package/components/cty-floating-panel.d.ts +1 -1
- package/components/cty-icon.d.ts +1 -1
- package/components/cty-image-upload.d.ts +1 -1
- package/components/cty-image-viewer.d.ts +1 -1
- package/components/cty-index-bar.d.ts +1 -1
- package/components/cty-keyboard.d.ts +1 -1
- package/components/cty-loading.d.ts +1 -1
- package/components/cty-media-capture.d.ts +1 -1
- package/components/cty-nav-bar.d.ts +1 -1
- package/components/cty-notice-bar.d.ts +1 -1
- package/components/cty-notice-bar.js +1 -1
- package/components/cty-overlay.d.ts +1 -1
- package/components/cty-pdf-viewer.d.ts +1 -1
- package/components/cty-permission-purpose.d.ts +1 -1
- package/components/cty-progress.d.ts +1 -1
- package/components/cty-quick-access.d.ts +1 -1
- package/components/cty-rate.d.ts +1 -1
- package/components/cty-record.d.ts +1 -1
- package/components/cty-segment-slides.d.ts +1 -1
- package/components/cty-share-sheet.d.ts +1 -1
- package/components/cty-step.d.ts +1 -1
- package/components/cty-stepper.d.ts +1 -1
- package/components/cty-steps.d.ts +1 -1
- package/components/cty-swipe-item.d.ts +1 -1
- package/components/cty-swipe.d.ts +1 -1
- package/components/cty-swiper.d.ts +1 -1
- package/components/cty-text-ellipsis.d.ts +1 -1
- package/components/cty-tour.d.ts +1 -1
- package/components/cty-tutorial.d.ts +1 -1
- package/components/cty-video.d.ts +1 -1
- package/components/cty-video.js +6 -4
- package/components/cty-virtual-list.d.ts +1 -1
- package/css/core.css +1 -1
- package/css/core.css.map +1 -1
- package/css/cty-mui.bundle.css +1 -1
- package/css/cty-mui.bundle.css.map +1 -1
- package/dist/cjs/cty-camera-photo.cjs.entry.js +3 -3
- package/dist/cjs/cty-cascader.cjs.entry.js +65 -28
- package/dist/cjs/cty-crop-image.cjs.entry.js +2 -2
- package/dist/cjs/cty-mui.cjs.js +1 -1
- package/dist/cjs/cty-notice-bar.cjs.entry.js +1 -1
- package/dist/cjs/cty-video.cjs.entry.js +5 -4
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/camera-photo/camera-photo.js +9 -3
- package/dist/collection/components/cascader/cascader.js +65 -28
- package/dist/collection/components/crop-image/crop-image.css +3 -1
- package/dist/collection/components/crop-image/crop-image.js +1 -1
- package/dist/collection/components/notice-bar/notice-bar.css +12 -12
- package/dist/collection/components/video/video.js +25 -4
- package/dist/cty-mui/cty-mui.esm.js +1 -1
- package/dist/cty-mui/p-13f6b4cf.system.entry.js +1 -0
- package/dist/cty-mui/p-16c44e92.system.js +1 -1
- package/dist/cty-mui/p-3bbb5110.entry.js +1 -0
- package/dist/cty-mui/{p-0cf8450c.system.entry.js → p-3d5125fd.system.entry.js} +1 -1
- package/dist/cty-mui/{p-0065ca91.entry.js → p-4feaf144.entry.js} +1 -1
- package/dist/cty-mui/{p-411955a6.system.entry.js → p-80f612bc.system.entry.js} +1 -1
- package/dist/cty-mui/{p-62a82a6d.system.entry.js → p-93f1e37a.system.entry.js} +1 -1
- package/dist/cty-mui/{p-ab9c425d.entry.js → p-adddcc45.entry.js} +1 -1
- package/dist/cty-mui/p-b2847692.system.entry.js +1 -0
- package/dist/cty-mui/p-c4f96fc0.entry.js +1 -0
- package/dist/cty-mui/p-cc3d9063.entry.js +1 -0
- package/dist/docs.json +25 -1
- package/dist/esm/cty-camera-photo.entry.js +3 -3
- package/dist/esm/cty-cascader.entry.js +65 -28
- package/dist/esm/cty-crop-image.entry.js +2 -2
- package/dist/esm/cty-mui.js +1 -1
- package/dist/esm/cty-notice-bar.entry.js +1 -1
- package/dist/esm/cty-video.entry.js +5 -4
- package/dist/esm/loader.js +1 -1
- package/dist/esm-es5/cty-camera-photo.entry.js +1 -1
- package/dist/esm-es5/cty-cascader.entry.js +1 -1
- package/dist/esm-es5/cty-crop-image.entry.js +1 -1
- package/dist/esm-es5/cty-mui.js +1 -1
- package/dist/esm-es5/cty-notice-bar.entry.js +1 -1
- package/dist/esm-es5/cty-video.entry.js +1 -1
- package/dist/esm-es5/loader.js +1 -1
- package/dist/types/components/camera-photo/camera-photo.d.ts +2 -2
- package/dist/types/components/cascader/cascader.d.ts +3 -2
- package/dist/types/components/video/video.d.ts +1 -0
- package/dist/types/components.d.ts +2 -0
- package/package.json +1 -1
- package/dist/cty-mui/p-418a5c0c.system.entry.js +0 -1
- package/dist/cty-mui/p-51dc32d0.entry.js +0 -1
- package/dist/cty-mui/p-529e2563.system.entry.js +0 -1
- package/dist/cty-mui/p-eb74a116.entry.js +0 -1
- package/dist/cty-mui/p-fa724d72.entry.js +0 -1
package/components/crop-image.js
CHANGED
|
@@ -2,7 +2,7 @@ import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/
|
|
|
2
2
|
import { a as getElementRect, b as getEventPageCoords } from './dom.js';
|
|
3
3
|
import { c as clamp } from './format2.js';
|
|
4
4
|
|
|
5
|
-
const cropImageCss = "*{-webkit-box-sizing:border-box;box-sizing:border-box}p,h1,h2,h3,h4,h5,h6{margin:0;padding:0}.flex{display:-ms-flexbox;display:flex}.flex-wrap{display:-ms-flexbox;display:flex;-ms-flex-flow:wrap;flex-flow:wrap}.flex-align-start{display:-ms-flexbox;display:flex;-ms-flex-align:start;align-items:flex-start}.flex-align-center{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}.flex-align-end{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end}.flex-justify-start{display:-ms-flexbox;display:flex;-ms-flex-pack:start;justify-content:flex-start}.flex-justify-center{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center}.flex-justify-end{display:-ms-flexbox;display:flex;-ms-flex-pack:end;justify-content:flex-end}.flex-align-end-start{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end;-ms-flex-pack:start;justify-content:flex-start}.flex-align-end-center{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end;-ms-flex-pack:center;justify-content:center}.flex-align-end-end{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end;-ms-flex-pack:end;justify-content:flex-end}.flex-center{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center}.flex-center-justify-end{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:end;justify-content:flex-end}.flex-between{display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between}.flex-center-between{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;justify-content:space-between}.flex-column{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column}.flex-column-align-center{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-align:center;align-items:center}.flex-column-justify-center{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-pack:center;justify-content:center}.flex-column-center{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center}.flex-column-between{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-pack:justify;justify-content:space-between}.flex-column-center-between{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;justify-content:space-between}.plt-hybrid .safe-area-bottom-border{-webkit-box-sizing:content-box;box-sizing:content-box;border-bottom:var(--ion-safe-area-bottom, 0) solid var(--cty-color-white)}.plt-hybrid .safe-area-bottom-border-color{-webkit-box-sizing:content-box;box-sizing:content-box;border-bottom:var(--ion-safe-area-bottom, 0) solid currentColor}.plt-hybrid .safe-area-bottom-padding{padding-bottom:var(--ion-safe-area-bottom, 0)}.cty-button-native{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;margin:0;padding:0;background:transparent;font-family:inherit;font-size:inherit;font-style:inherit;font-weight:inherit;letter-spacing:inherit;text-decoration:inherit;text-indent:inherit;text-overflow:inherit;text-transform:inherit;text-align:inherit;white-space:inherit;color:inherit;line-height:1;border:0;outline:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:0;-webkit-box-shadow:none;box-shadow:none;cursor:pointer}:host{--cty-crop-image-clip-width:100vw;--cty-crop-image-clip-height:100vw;--cty-crop-image-clip-background:var(--cty-overlay-color);--cty-crop-image-clip-border:1px solid #767676;--cty-crop-image-buttons-padding:12px 0;--cty-crop-image-button-padding:0 12px;--cty-crop-image-button-color:var(--cty-color-white);--cty-crop-image-button-active-color:var(--cty-color-white);--cty-crop-image-button-size:var(--cty-font-size-base);--cty-crop-image-button-line-height:30px;--cty-crop-image-button-weight:400;display:
|
|
5
|
+
const cropImageCss = "*{-webkit-box-sizing:border-box;box-sizing:border-box}p,h1,h2,h3,h4,h5,h6{margin:0;padding:0}.flex{display:-ms-flexbox;display:flex}.flex-wrap{display:-ms-flexbox;display:flex;-ms-flex-flow:wrap;flex-flow:wrap}.flex-align-start{display:-ms-flexbox;display:flex;-ms-flex-align:start;align-items:flex-start}.flex-align-center{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}.flex-align-end{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end}.flex-justify-start{display:-ms-flexbox;display:flex;-ms-flex-pack:start;justify-content:flex-start}.flex-justify-center{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center}.flex-justify-end{display:-ms-flexbox;display:flex;-ms-flex-pack:end;justify-content:flex-end}.flex-align-end-start{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end;-ms-flex-pack:start;justify-content:flex-start}.flex-align-end-center{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end;-ms-flex-pack:center;justify-content:center}.flex-align-end-end{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end;-ms-flex-pack:end;justify-content:flex-end}.flex-center{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center}.flex-center-justify-end{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:end;justify-content:flex-end}.flex-between{display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between}.flex-center-between{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;justify-content:space-between}.flex-column{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column}.flex-column-align-center{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-align:center;align-items:center}.flex-column-justify-center{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-pack:center;justify-content:center}.flex-column-center{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center}.flex-column-between{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-pack:justify;justify-content:space-between}.flex-column-center-between{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;justify-content:space-between}.plt-hybrid .safe-area-bottom-border{-webkit-box-sizing:content-box;box-sizing:content-box;border-bottom:var(--ion-safe-area-bottom, 0) solid var(--cty-color-white)}.plt-hybrid .safe-area-bottom-border-color{-webkit-box-sizing:content-box;box-sizing:content-box;border-bottom:var(--ion-safe-area-bottom, 0) solid currentColor}.plt-hybrid .safe-area-bottom-padding{padding-bottom:var(--ion-safe-area-bottom, 0)}.cty-button-native{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;margin:0;padding:0;background:transparent;font-family:inherit;font-size:inherit;font-style:inherit;font-weight:inherit;letter-spacing:inherit;text-decoration:inherit;text-indent:inherit;text-overflow:inherit;text-transform:inherit;text-align:inherit;white-space:inherit;color:inherit;line-height:1;border:0;outline:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:0;-webkit-box-shadow:none;box-shadow:none;cursor:pointer}:host{--cty-crop-image-clip-width:100vw;--cty-crop-image-clip-height:100vw;--cty-crop-image-clip-background:var(--cty-overlay-color);--cty-crop-image-clip-border:1px solid #767676;--cty-crop-image-buttons-padding:12px 0;--cty-crop-image-button-padding:0 12px;--cty-crop-image-button-color:var(--cty-color-white);--cty-crop-image-button-active-color:var(--cty-color-white);--cty-crop-image-button-size:var(--cty-font-size-base);--cty-crop-image-button-line-height:30px;--cty-crop-image-button-weight:400;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;position:relative;width:100vw;height:100vh;background:var(--cty-color-black)}.cty-crop-image__wrapper{position:absolute;width:100%;left:50%;top:50%;-webkit-transform:translate(-50%, -50%) scale(1);transform:translate(-50%, -50%) scale(1)}.cty-crop-image__image{display:block;width:100%;pointer-events:none}.cty-crop-image__clip{position:relative;width:var(--cty-crop-image-clip-width);max-width:var(--cty-crop-image-width);height:var(--cty-crop-image-clip-height);border:var(--cty-crop-image-clip-border);-webkit-box-shadow:0 0 0 1000px var(--cty-crop-image-clip-background);box-shadow:0 0 0 1000px var(--cty-crop-image-clip-background)}.cty-crop-image__buttons{position:absolute;left:0;right:0;bottom:0;background-color:rgba(19, 19, 19, 0.7);padding:var(--cty-crop-image-buttons-padding)}.cty-crop-image__button{padding:var(--cty-crop-image-button-padding);font-size:var(--cty-crop-image-button-size);color:var(--cty-crop-image-button-color);line-height:var(--cty-crop-image-button-line-height);font-weight:var(--cty-crop-image-button-weight)}.cty-crop-image__button+.cty-crop-image__button{color:var(--cty-crop-image-button-active-color)}";
|
|
6
6
|
const CtyCropImageStyle0 = cropImageCss;
|
|
7
7
|
|
|
8
8
|
const CropImage = /*@__PURE__*/ proxyCustomElement(class CropImage extends HTMLElement {
|
|
@@ -209,7 +209,7 @@ const CropImage = /*@__PURE__*/ proxyCustomElement(class CropImage extends HTMLE
|
|
|
209
209
|
return (h("div", { class: "cty-crop-image__buttons flex-center-between safe-area-bottom-border-color" }, this.cancelText && cancelCmp, this.confirmText && confirmCmp));
|
|
210
210
|
}
|
|
211
211
|
render() {
|
|
212
|
-
return (h(Host, { key: '
|
|
212
|
+
return (h(Host, { key: '188bc6a88e6b45cbd7b96fc4969ac0f4bcfc6d32', class: "cty-crop-image", onMouseDown: (e) => this.doTouchStart(e), onTouchStart: (e) => this.doTouchStart(e), onTouchMove: (e) => this.doTouchMove(e), onTouchEnd: () => this.doTouchEnd() }, h("slot", { key: '1fd8366eceecef4740ac06a86118dbd318df4efe', name: "header" }), h("div", { key: '5f6315fa7b4684dff0b3d5273bf836a79274c780', class: "cty-crop-image__wrapper", ref: el => (this.imageEl = el) }, h("img", { key: 'eac5e99cf3ed23aa5dda6ad784463e5f3dc51902', src: this.url, class: "cty-crop-image__image" })), h("div", { key: '042df69d9a69af60af0fdbe47a19ab25866ea0fe', class: "cty-crop-image__clip", ref: el => (this.clipEl = el) }), h("slot", { key: '6bf8feeadf7f9679c5b1a8405514b13b6fda4590', name: "clip" }), this.renderButtons(), h("slot", { key: 'c7615d81bcf106c0ef2f38fde394874a0b802cda', name: "footer" })));
|
|
213
213
|
}
|
|
214
214
|
get el() { return this; }
|
|
215
215
|
static get style() { return CtyCropImageStyle0; }
|
|
@@ -229,8 +229,6 @@ const CameraPhoto = /*@__PURE__*/ proxyCustomElement(class CameraPhoto extends H
|
|
|
229
229
|
this.isMicroMessager = deviceInfo$1.isMicroMessager;
|
|
230
230
|
this.isIOS = deviceInfo$1.isIos;
|
|
231
231
|
this.allowEdit = false;
|
|
232
|
-
this.showCropImage = false;
|
|
233
|
-
this.clipImage = '';
|
|
234
232
|
this.imageSource = { option: { action: '' }, imageList: [], index: 0 };
|
|
235
233
|
this.showPermissionPurpose = false;
|
|
236
234
|
this.permissionDescription = '';
|
|
@@ -274,6 +272,8 @@ const CameraPhoto = /*@__PURE__*/ proxyCustomElement(class CameraPhoto extends H
|
|
|
274
272
|
this.leaveAnimation = undefined;
|
|
275
273
|
this.enterAnimation = undefined;
|
|
276
274
|
this.trigger = undefined;
|
|
275
|
+
this.showCropImage = false;
|
|
276
|
+
this.clipImage = '';
|
|
277
277
|
}
|
|
278
278
|
triggerChanged() {
|
|
279
279
|
const { trigger, el, triggerController } = this;
|
|
@@ -394,7 +394,7 @@ const CameraPhoto = /*@__PURE__*/ proxyCustomElement(class CameraPhoto extends H
|
|
|
394
394
|
this.ctyTap.emit({ index, imageList });
|
|
395
395
|
}
|
|
396
396
|
render() {
|
|
397
|
-
return (h(Host, { key: '
|
|
397
|
+
return (h(Host, { key: '8c7f1d5a4b16fd591de7ff1f82830e4ad6381230', class: Object.assign(Object.assign({}, getClassMap(this.cssClass)), { 'overlay-hidden': true, 'cty-pos-cover': this.overlay }), style: { zIndex: `${20000 + this.overlayIndex}` } }, h("cty-action-sheet", { key: 'badb995c2e5198b1a64c75f3e8a33fc94d52bd12', animated: false, overlayIndex: 1, backdropDismiss: this.backdropDismiss, title: this.title, closeable: this.closeable, closeIcon: this.closeIcon, cancelText: this.cancelText, options: this.options, onCtyDismiss: () => this.dismiss(), onCtyTap: e => this._buttonClick(e) }), this.showCropImage && (h("cty-overlay", { key: '36b4365c3b082fb4628edf7273e2fdd56ad7af47', animated: false, backdropDismiss: false }, h("cty-crop-image", { key: '4d5d442966f50e937c37c754504ad43b0593f0b8', url: this.clipImage, cancelText: this.clipCancelText, confirmText: this.clipCconfirmText, imageWidth: this.clipImageWidth, imageBackground: this.clipImageBg, maxScale: this.clipMaxScale, minScale: this.clipMinScale, suffix: this.clipImageSuffix, quality: this.clipImageQuality, onCtyCancel: () => this._doCropCancel(), onCtyConfirm: (e) => this._doCropConfirm(e) }))), this.showPermissionPurpose && h("cty-permission-purpose", { key: '263297537bcaf5636696183d4a5755d13bc7b4bd', description: this.permissionDescription })));
|
|
398
398
|
}
|
|
399
399
|
get el() { return this; }
|
|
400
400
|
static get watchers() { return {
|
|
@@ -431,6 +431,8 @@ const CameraPhoto = /*@__PURE__*/ proxyCustomElement(class CameraPhoto extends H
|
|
|
431
431
|
"leaveAnimation": [16],
|
|
432
432
|
"enterAnimation": [16],
|
|
433
433
|
"trigger": [1],
|
|
434
|
+
"showCropImage": [32],
|
|
435
|
+
"clipImage": [32],
|
|
434
436
|
"present": [64],
|
|
435
437
|
"dismiss": [64],
|
|
436
438
|
"onDidDismiss": [64],
|
|
@@ -13537,7 +13537,8 @@ const Cascader = /*@__PURE__*/ proxyCustomElement(class Cascader extends HTMLEle
|
|
|
13537
13537
|
mousemoving: false,
|
|
13538
13538
|
};
|
|
13539
13539
|
this.firstRender = true;
|
|
13540
|
-
this.
|
|
13540
|
+
this.changeColumnIndex = null;
|
|
13541
|
+
this.prevColumns = [];
|
|
13541
13542
|
// Controller
|
|
13542
13543
|
this.delegateController = createDelegateController(this);
|
|
13543
13544
|
this.lockController = createLockController();
|
|
@@ -13602,13 +13603,24 @@ const Cascader = /*@__PURE__*/ proxyCustomElement(class Cascader extends HTMLEle
|
|
|
13602
13603
|
this.triggerController.removeClickListener();
|
|
13603
13604
|
//this.presented && this.dismiss();
|
|
13604
13605
|
}
|
|
13605
|
-
|
|
13606
|
-
|
|
13606
|
+
columnsOrValueChange(newValue) {
|
|
13607
|
+
var _a;
|
|
13608
|
+
this.changeColumnIndex = [];
|
|
13609
|
+
if (((_a = this.prevColumns) === null || _a === void 0 ? void 0 : _a.length) && (newValue === null || newValue === void 0 ? void 0 : newValue.length)) {
|
|
13610
|
+
for (let i = 0; i < newValue.length; i++) {
|
|
13611
|
+
if ((newValue[i] || this.prevColumns[i]) && JSON.stringify(newValue[i]) != JSON.stringify(this.prevColumns[i]))
|
|
13612
|
+
this.changeColumnIndex.push(i);
|
|
13613
|
+
}
|
|
13614
|
+
}
|
|
13615
|
+
if (this.type === 'default' && !this.cascade) {
|
|
13616
|
+
this.prevColumns = JSON.parse(JSON.stringify(newValue));
|
|
13617
|
+
}
|
|
13607
13618
|
this.initScrollColumns();
|
|
13608
13619
|
}
|
|
13609
13620
|
componentWillLoad() {
|
|
13610
13621
|
prepareOverlay(this.el);
|
|
13611
|
-
this.
|
|
13622
|
+
if (this.type === 'default' && !this.cascade)
|
|
13623
|
+
this.prevColumns = JSON.parse(JSON.stringify(this.columns));
|
|
13612
13624
|
this.triggerChanged();
|
|
13613
13625
|
this.initDimensions();
|
|
13614
13626
|
this.initScrollColumns();
|
|
@@ -13637,27 +13649,52 @@ const Cascader = /*@__PURE__*/ proxyCustomElement(class Cascader extends HTMLEle
|
|
|
13637
13649
|
}
|
|
13638
13650
|
}
|
|
13639
13651
|
normalizeNormalMode(columns) {
|
|
13640
|
-
|
|
13641
|
-
|
|
13642
|
-
const
|
|
13643
|
-
|
|
13644
|
-
|
|
13645
|
-
|
|
13646
|
-
|
|
13647
|
-
|
|
13648
|
-
|
|
13649
|
-
|
|
13650
|
-
|
|
13651
|
-
|
|
13652
|
-
|
|
13653
|
-
|
|
13654
|
-
|
|
13655
|
-
|
|
13656
|
-
|
|
13657
|
-
|
|
13658
|
-
|
|
13659
|
-
|
|
13660
|
-
|
|
13652
|
+
let _scrollColumns = this.scrollColumns;
|
|
13653
|
+
if (this.changeColumnIndex === null) {
|
|
13654
|
+
const visibleColumns = this.columnsCount != null ? columns.slice(0, this.columnsCount) : columns;
|
|
13655
|
+
_scrollColumns = visibleColumns.map((column, idx) => {
|
|
13656
|
+
const scrollColumn = {
|
|
13657
|
+
id: this.sid++,
|
|
13658
|
+
prevY: 0,
|
|
13659
|
+
momentumPrevY: 0,
|
|
13660
|
+
touching: false,
|
|
13661
|
+
translate: this.center,
|
|
13662
|
+
index: 0,
|
|
13663
|
+
duration: 0,
|
|
13664
|
+
momentumTime: 0,
|
|
13665
|
+
column,
|
|
13666
|
+
scrollEl: null,
|
|
13667
|
+
scrolling: false,
|
|
13668
|
+
};
|
|
13669
|
+
const value = this.defaultValues[idx];
|
|
13670
|
+
const index = scrollColumn.column.findIndex(option => value === this.getValue(option));
|
|
13671
|
+
scrollColumn.index = index === -1 ? 0 : index;
|
|
13672
|
+
this.scrollTo(scrollColumn);
|
|
13673
|
+
return scrollColumn;
|
|
13674
|
+
});
|
|
13675
|
+
}
|
|
13676
|
+
else if (this.changeColumnIndex.length) {
|
|
13677
|
+
for (let i = 0; i < this.changeColumnIndex.length; i++) {
|
|
13678
|
+
if (!this.columnsCount || this.changeColumnIndex[i] <= this.columnsCount) {
|
|
13679
|
+
_scrollColumns[this.changeColumnIndex[i]] = {
|
|
13680
|
+
id: this.sid++,
|
|
13681
|
+
prevY: 0,
|
|
13682
|
+
momentumPrevY: 0,
|
|
13683
|
+
touching: false,
|
|
13684
|
+
translate: this.center,
|
|
13685
|
+
index: 0,
|
|
13686
|
+
duration: 0,
|
|
13687
|
+
momentumTime: 0,
|
|
13688
|
+
column: this.columns[this.changeColumnIndex[i]],
|
|
13689
|
+
scrollEl: null,
|
|
13690
|
+
scrolling: false,
|
|
13691
|
+
};
|
|
13692
|
+
this.updateScrollEl();
|
|
13693
|
+
this.scrollTo(_scrollColumns[this.changeColumnIndex[i]]);
|
|
13694
|
+
}
|
|
13695
|
+
}
|
|
13696
|
+
}
|
|
13697
|
+
return _scrollColumns;
|
|
13661
13698
|
}
|
|
13662
13699
|
normalizeCascadeMode(column) {
|
|
13663
13700
|
const scrollColumns = [];
|
|
@@ -13681,7 +13718,7 @@ const Cascader = /*@__PURE__*/ proxyCustomElement(class Cascader extends HTMLEle
|
|
|
13681
13718
|
};
|
|
13682
13719
|
scrollColumns.push(scrollColumn);
|
|
13683
13720
|
if (syncModelValue) {
|
|
13684
|
-
const value = this.
|
|
13721
|
+
const value = this.defaultValues[scrollColumns.length - 1];
|
|
13685
13722
|
const index = children.findIndex(option => value === this.getValue(option));
|
|
13686
13723
|
scrollColumn.index = index === -1 ? 0 : index;
|
|
13687
13724
|
}
|
|
@@ -13879,12 +13916,12 @@ const Cascader = /*@__PURE__*/ proxyCustomElement(class Cascader extends HTMLEle
|
|
|
13879
13916
|
this.ctyConfirm.emit({ values, indexes, options });
|
|
13880
13917
|
}
|
|
13881
13918
|
render() {
|
|
13882
|
-
return (h(Host, { key: '
|
|
13919
|
+
return (h(Host, { key: '982f2c8b5e14455c6699678b34590c80be14c21c', class: Object.assign(Object.assign({}, getClassMap(this.cssClass)), { 'overlay-hidden': true }), style: { zIndex: `${20000 + this.overlayIndex}` } }, h("cty-overlay", { key: 'cd29455bc7a10a238ad6b9e4d1b0047b04eb3c2b', animated: false, backdropDismiss: this.backdropDismiss, onCtyDismiss: () => this.dismiss() }, h("div", { key: '4a5e3bac012d307fb7db148bbfdbff61d93eb855', class: "cty-cascader-container", ref: (el) => (this.cascaderContainerEl = el) }, h("div", { key: '2a9eeaf8b0cfbc8d9bbe73e997ce1b5c4e0e2095', class: "cty-cascader", onClick: (e) => e.stopPropagation() }, h("slot", { key: '00748a78ef1ae0f4bf61b74ed56f952aff909b2f', name: 'header' }), h("div", { key: 'a3335aec11f69c550f2beabcc215d02f4dffa3da', class: "cty-cascader-header" }, h("button", { key: '24127ee47aef6267435c21f25d7d856bd8ab15c8', onClick: () => this.dismiss(), class: "cancel cty-button-native" }, this.cancelText), h("div", { key: '9e9d9a571be493bf73a6478fa01fa0715a3f8b74', class: "cty-cascader-title" }, this.title), h("button", { key: '09f02cc628b54f8cd6f6d68e3682b70b951f4afb', onClick: () => this.confirm(), class: "confirm cty-button-native" }, this.confirmText)), h("div", { key: '73c17ca25e9b7f7e1c28ea923f019d578869c63e', class: "cty-cascader-columns", style: { height: this.columnHeight + 'px' } }, this.scrollColumns.map(c => h("div", { class: "cty-cascader-column", onTouchStart: (e) => this.handleTouchstart(e, c), onTouchMove: (e) => this.handleTouchmove(e, c), onTouchEnd: () => this.handleTouchend(c), onMouseDown: (e) => this.handleTouchstart(e, c), onMouseMove: (e) => this.handleTouchmove(e, c), onMouseUp: () => this.handleTouchend(c) }, h("div", { class: "cty-cascader-scroller", style: { transform: 'translateY(' + c.translate + 'px)', 'transition-duration': c.duration + 'ms', 'transition-property': c.duration ? 'transform' : 'none' }, onTransitionEnd: () => this.handleTransitionend(c) }, c.column.map((option, i) => h("div", { class: 'cty-cascader-option ' + (option.className || ''), style: { height: this.optionHeight + 'px' }, onClick: () => this.handleClick(c, i) }, h("div", { class: 'cty-cascader-text ' + (option.textClassName || '') }, option[this.textKey])))))), h("div", { key: 'd32d3c1b44d2a0c7c9d48e0c751d57e933bfb90b', class: "cty-cascader-picked", style: { top: this.center + 'px', height: this.optionHeight + 'px' } }), h("div", { key: 'eba4be575f9834abf38208163636f11c49f153e7', class: "cty-cascader-mask", style: { 'background-size': '100% ' + (this.columnHeight - this.optionHeight) / 2 + 'px' } })))))));
|
|
13883
13920
|
}
|
|
13884
13921
|
get el() { return this; }
|
|
13885
13922
|
static get watchers() { return {
|
|
13886
13923
|
"trigger": ["triggerChanged"],
|
|
13887
|
-
"columns": ["
|
|
13924
|
+
"columns": ["columnsOrValueChange"]
|
|
13888
13925
|
}; }
|
|
13889
13926
|
static get style() { return CtyCascaderStyle0; }
|
|
13890
13927
|
}, [1, "cty-cascader", {
|
|
@@ -13918,7 +13955,7 @@ const Cascader = /*@__PURE__*/ proxyCustomElement(class Cascader extends HTMLEle
|
|
|
13918
13955
|
"onWillDismiss": [64]
|
|
13919
13956
|
}, undefined, {
|
|
13920
13957
|
"trigger": ["triggerChanged"],
|
|
13921
|
-
"columns": ["
|
|
13958
|
+
"columns": ["columnsOrValueChange"]
|
|
13922
13959
|
}]);
|
|
13923
13960
|
function defineCustomElement$1() {
|
|
13924
13961
|
if (typeof customElements === "undefined") {
|
package/components/cty-icon.d.ts
CHANGED
|
@@ -4,7 +4,7 @@ import './gesture-controller.js';
|
|
|
4
4
|
import { d as defineCustomElement$3 } from './icon.js';
|
|
5
5
|
import { d as defineCustomElement$2 } from './icon2.js';
|
|
6
6
|
|
|
7
|
-
const noticeBarCss = "*{-webkit-box-sizing:border-box;box-sizing:border-box}p,h1,h2,h3,h4,h5,h6{margin:0;padding:0}.flex{display:-ms-flexbox;display:flex}.flex-wrap{display:-ms-flexbox;display:flex;-ms-flex-flow:wrap;flex-flow:wrap}.flex-align-start{display:-ms-flexbox;display:flex;-ms-flex-align:start;align-items:flex-start}.flex-align-center{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}.flex-align-end{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end}.flex-justify-start{display:-ms-flexbox;display:flex;-ms-flex-pack:start;justify-content:flex-start}.flex-justify-center{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center}.flex-justify-end{display:-ms-flexbox;display:flex;-ms-flex-pack:end;justify-content:flex-end}.flex-align-end-start{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end;-ms-flex-pack:start;justify-content:flex-start}.flex-align-end-center{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end;-ms-flex-pack:center;justify-content:center}.flex-align-end-end{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end;-ms-flex-pack:end;justify-content:flex-end}.flex-center{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center}.flex-center-justify-end{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:end;justify-content:flex-end}.flex-between{display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between}.flex-center-between{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;justify-content:space-between}.flex-column{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column}.flex-column-align-center{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-align:center;align-items:center}.flex-column-justify-center{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-pack:center;justify-content:center}.flex-column-center{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center}.flex-column-between{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-pack:justify;justify-content:space-between}.flex-column-center-between{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;justify-content:space-between}.cty-ellipsis[class]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;line-height:normal}.cty-ellipsis2[class]{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden;word-break:break-all;word-wrap:break-word}.cty-ellipsis3[class]{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:3;overflow:hidden;word-break:break-all;word-wrap:break-word}.cty-ellipsis4[class]{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:4;overflow:hidden;word-break:break-all;word-wrap:break-word}.cty-button-native{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;margin:0;padding:0;background:transparent;font-family:inherit;font-size:inherit;font-style:inherit;font-weight:inherit;letter-spacing:inherit;text-decoration:inherit;text-indent:inherit;text-overflow:inherit;text-transform:inherit;text-align:inherit;white-space:inherit;color:inherit;line-height:1;border:0;outline:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:0;-webkit-box-shadow:none;box-shadow:none;cursor:pointer}:host{--cty-notice-bar-text-color:var(--cty-color-primary);--cty-notice-bar-text-font-size:var(--cty-font-size-base);--cty-notice-bar-text-line-height:24px;--cty-notice-bar-font-weight:normal;--cty-notice-bar-text-white-space:nowrap;--cty-notice-bar-text-word-wrap:initial;--cty-notice-bar-icon-
|
|
7
|
+
const noticeBarCss = "*{-webkit-box-sizing:border-box;box-sizing:border-box}p,h1,h2,h3,h4,h5,h6{margin:0;padding:0}.flex{display:-ms-flexbox;display:flex}.flex-wrap{display:-ms-flexbox;display:flex;-ms-flex-flow:wrap;flex-flow:wrap}.flex-align-start{display:-ms-flexbox;display:flex;-ms-flex-align:start;align-items:flex-start}.flex-align-center{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}.flex-align-end{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end}.flex-justify-start{display:-ms-flexbox;display:flex;-ms-flex-pack:start;justify-content:flex-start}.flex-justify-center{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center}.flex-justify-end{display:-ms-flexbox;display:flex;-ms-flex-pack:end;justify-content:flex-end}.flex-align-end-start{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end;-ms-flex-pack:start;justify-content:flex-start}.flex-align-end-center{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end;-ms-flex-pack:center;justify-content:center}.flex-align-end-end{display:-ms-flexbox;display:flex;-ms-flex-align:end;align-items:flex-end;-ms-flex-pack:end;justify-content:flex-end}.flex-center{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center}.flex-center-justify-end{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:end;justify-content:flex-end}.flex-between{display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between}.flex-center-between{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;justify-content:space-between}.flex-column{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column}.flex-column-align-center{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-align:center;align-items:center}.flex-column-justify-center{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-pack:center;justify-content:center}.flex-column-center{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center}.flex-column-between{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-pack:justify;justify-content:space-between}.flex-column-center-between{display:-ms-flexbox;display:flex;-ms-flex-flow:column;flex-flow:column;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;justify-content:space-between}.cty-ellipsis[class]{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;line-height:normal}.cty-ellipsis2[class]{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden;word-break:break-all;word-wrap:break-word}.cty-ellipsis3[class]{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:3;overflow:hidden;word-break:break-all;word-wrap:break-word}.cty-ellipsis4[class]{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:4;overflow:hidden;word-break:break-all;word-wrap:break-word}.cty-button-native{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;margin:0;padding:0;background:transparent;font-family:inherit;font-size:inherit;font-style:inherit;font-weight:inherit;letter-spacing:inherit;text-decoration:inherit;text-indent:inherit;text-overflow:inherit;text-transform:inherit;text-align:inherit;white-space:inherit;color:inherit;line-height:1;border:0;outline:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:0;-webkit-box-shadow:none;box-shadow:none;cursor:pointer}:host{--cty-notice-bar-text-color:var(--cty-color-primary);--cty-notice-bar-text-font-size:var(--cty-font-size-base);--cty-notice-bar-text-line-height:24px;--cty-notice-bar-font-weight:normal;--cty-notice-bar-text-white-space:nowrap;--cty-notice-bar-text-word-wrap:initial;--cty-notice-bar-icon-start-size:var(--cty-font-size-medium);--cty-notice-bar-icon-start-color:var(--cty-color-primary);--cty-notice-bar-icon-start-min-width:24px;--cty-notice-bar-icon-end-size:var(--cty-font-size-medium);--cty-notice-bar-icon-end-color:var(--cty-color-primary);--cty-notice-bar-icon-end-min-width:24px;position:relative;background:#fffbe8;padding:8px 16px;cursor:pointer}.cty-notice-bar__start-icon{-ms-flex-pack:start;justify-content:flex-start;min-width:var(--cty-notice-bar-icon-start-min-width);margin:0;font-size:var(--cty-notice-bar-icon-start-size);color:var(--cty-notice-bar-icon-start-color)}.cty-notice-bar__end-icon{display:-ms-inline-flexbox;display:inline-flex;-ms-flex-pack:end;justify-content:flex-end;min-width:var(--cty-notice-bar-icon-end-min-width);font-size:var(--cty-notice-bar-icon-end-size);color:var(--cty-notice-bar-icon-end-color);text-align:right}.cty-notice-bar__wrap{overflow:hidden;position:relative;-ms-flex:1;flex:1;height:100%}.cty-notice-bar__content[class]{position:relative;width:100%;color:var(--cty-notice-bar-text-color);font-size:var(--cty-notice-bar-text-font-size);line-height:var(--cty-notice-bar-text-line-height);white-space:var(--cty-notice-bar-text-white-space);word-wrap:var(--cty-notice-bar-text-word-wrap);font-weight:var(--cty-notice-bar-font-weight);-webkit-transition-timing-function:linear;transition-timing-function:linear}";
|
|
8
8
|
const CtyNoticeBarStyle0 = noticeBarCss;
|
|
9
9
|
|
|
10
10
|
const NoticeBar = /*@__PURE__*/ proxyCustomElement(class NoticeBar extends HTMLElement {
|
package/components/cty-rate.d.ts
CHANGED
package/components/cty-step.d.ts
CHANGED
package/components/cty-tour.d.ts
CHANGED