diff --git a/src/layer/index.wc b/src/layer/index.wc index b95c638..99f76d4 100644 --- a/src/layer/index.wc +++ b/src/layer/index.wc @@ -95,7 +95,7 @@ ::slotted(&__input) { flex: 1; - height: 32px; + height: 36px; } ::slotted(&__frame) { @@ -589,6 +589,8 @@ export default class Layer { unmount() { $.clearOutside(this._handlMask) $.unbind(this.__TITLE__, 'click', this._handleClose) + $.unbind(this.__CTRL__, 'click', this._handleBtnClick) + this._handleSubmit && $.unbind(this.__INPUT__, 'submit', this._handleSubmit) } watch() { @@ -733,11 +735,23 @@ Object.assign(_layer, { intercept }) }, - prompt(title = lang.TITLE, intercept) { + prompt(title = lang.TITLE, defaultValue = '', intercept) { + if (typeof defaultValue === 'function') { + intercept = defaultValue + defaultValue = '' + } + + if (!intercept) { + intercept = function(val, done) { + if (val) { + done() + } + } + } return this({ type: 'prompt', title, - content: ``, + content: ``, mask: true, intercept }) diff --git a/src/picker/date.wc b/src/picker/date.wc index 0ca8e64..6bb1f13 100644 --- a/src/picker/date.wc +++ b/src/picker/date.wc @@ -208,10 +208,10 @@ } :host(:focus-within) { - @include focus1; + // @include focus1; } :host(:focus-within[readonly]) { - @include focus2; + // @include focus2; } :host([disabled]) { opacity: 0.6;