yc-design-vue 2.1.9 → 2.2.0
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/dist/index.umd.js +1 -1
- package/dist/style.css +1 -1
- package/es/Avatar/Avatar.vue.d.ts +1 -1
- package/es/Avatar/index.d.ts +3 -3
- package/es/Badge/index.d.ts +3 -3
- package/es/Badge/index.vue.d.ts +1 -1
- package/es/Button/Button.vue.d.ts +2 -2
- package/es/Button/ButtonGroup.vue.d.ts +1 -1
- package/es/Button/index.d.ts +9 -9
- package/es/Card/Card.vue.d.ts +1 -1
- package/es/Card/index.d.ts +3 -3
- package/es/Cascader/Cascader.vue.d.ts +12 -44
- package/es/Cascader/index.d.ts +6 -22
- package/es/Dropdown/DropdownButton.vue.d.ts +1 -1
- package/es/Dropdown/index.d.ts +3 -3
- package/es/Image/ImagePreviewToolbar.vue.js +6 -6
- package/es/Input/Input.vue.d.ts +2 -8
- package/es/Input/Input.vue.js +24 -46
- package/es/Input/InputPassword.vue.d.ts +309 -0
- package/es/Input/InputPassword.vue.js +122 -0
- package/es/Input/InputPassword.vue2.js +4 -0
- package/es/Input/InputSearch.vue.d.ts +310 -0
- package/es/Input/InputSearch.vue.js +133 -0
- package/es/Input/InputSearch.vue2.js +4 -0
- package/es/Input/hooks/useLimitedInput.d.ts +2 -0
- package/es/Input/hooks/useLimitedInput.js +2 -0
- package/es/Input/index.css +1 -1
- package/es/Input/index.d.ts +420 -23
- package/es/Input/index.js +11 -3
- package/es/Input/type.d.ts +24 -6
- package/es/InputNumber/InputNumber.vue.d.ts +12 -44
- package/es/InputNumber/index.d.ts +6 -22
- package/es/Link/index.d.ts +3 -3
- package/es/Link/index.vue.d.ts +1 -1
- package/es/Statistic/Statistic.vue.d.ts +1 -1
- package/es/Statistic/index.d.ts +3 -3
- package/es/Steps/Step.vue.d.ts +1 -1
- package/es/Steps/Steps.vue.d.ts +1 -1
- package/es/Steps/index.d.ts +6 -6
- package/es/Transfer/TransferPanel.vue.js +1 -1
- package/es/Typography/TypographyBase.vue.d.ts +12 -44
- package/es/Upload/UploadPictureCard.vue2.js +1 -1
- package/es/_shared/icons/IconEyeClose.vue.js +32 -1
- package/es/_shared/icons/IconEyeClose.vue2.js +1 -32
- package/es/_shared/icons/IconEyeOpen.vue.js +29 -1
- package/es/_shared/icons/IconEyeOpen.vue2.js +1 -29
- package/es/_shared/icons/IconFullScreen.vue.js +1 -28
- package/es/_shared/icons/IconFullScreen.vue2.js +28 -1
- package/es/_shared/icons/IconOriginSize.vue.js +1 -34
- package/es/_shared/icons/IconOriginSize.vue2.js +34 -1
- package/es/_shared/icons/IconRotateLeft.vue.js +1 -28
- package/es/_shared/icons/IconRotateLeft.vue2.js +28 -1
- package/es/_shared/icons/IconRotateRight.vue.js +1 -28
- package/es/_shared/icons/IconRotateRight.vue2.js +28 -1
- package/es/_shared/icons/IconSearch.vue.js +28 -1
- package/es/_shared/icons/IconSearch.vue2.js +1 -28
- package/es/_shared/icons/IconZoomIn.vue.js +1 -28
- package/es/_shared/icons/IconZoomIn.vue2.js +28 -1
- package/es/_shared/icons/IconZoomOut.vue.js +1 -28
- package/es/_shared/icons/IconZoomOut.vue2.js +28 -1
- package/es/index.d.ts +9 -9
- package/es/index.js +4 -0
- package/es/style.css +1 -1
- package/lib/Avatar/Avatar.vue.d.ts +1 -1
- package/lib/Avatar/index.d.ts +3 -3
- package/lib/Badge/index.d.ts +3 -3
- package/lib/Badge/index.vue.d.ts +1 -1
- package/lib/Button/Button.vue.d.ts +2 -2
- package/lib/Button/ButtonGroup.vue.d.ts +1 -1
- package/lib/Button/index.d.ts +9 -9
- package/lib/Card/Card.vue.d.ts +1 -1
- package/lib/Card/index.d.ts +3 -3
- package/lib/Cascader/Cascader.vue.d.ts +12 -44
- package/lib/Cascader/index.d.ts +6 -22
- package/lib/Dropdown/DropdownButton.vue.d.ts +1 -1
- package/lib/Dropdown/index.d.ts +3 -3
- package/lib/Image/ImagePreviewToolbar.vue.js +1 -1
- package/lib/Input/Input.vue.d.ts +2 -8
- package/lib/Input/Input.vue.js +1 -1
- package/lib/Input/InputPassword.vue.d.ts +309 -0
- package/lib/Input/InputPassword.vue.js +1 -0
- package/lib/Input/{InputSuffix.vue3.js → InputPassword.vue2.js} +1 -1
- package/lib/Input/InputSearch.vue.d.ts +310 -0
- package/lib/Input/InputSearch.vue.js +1 -0
- package/lib/Input/InputSearch.vue2.js +1 -0
- package/lib/Input/hooks/useLimitedInput.d.ts +2 -0
- package/lib/Input/hooks/useLimitedInput.js +1 -1
- package/lib/Input/index.css +1 -1
- package/lib/Input/index.d.ts +420 -23
- package/lib/Input/index.js +1 -1
- package/lib/Input/type.d.ts +24 -6
- package/lib/InputNumber/InputNumber.vue.d.ts +12 -44
- package/lib/InputNumber/index.d.ts +6 -22
- package/lib/Link/index.d.ts +3 -3
- package/lib/Link/index.vue.d.ts +1 -1
- package/lib/Statistic/Statistic.vue.d.ts +1 -1
- package/lib/Statistic/index.d.ts +3 -3
- package/lib/Steps/Step.vue.d.ts +1 -1
- package/lib/Steps/Steps.vue.d.ts +1 -1
- package/lib/Steps/index.d.ts +6 -6
- package/lib/Transfer/TransferPanel.vue.js +1 -1
- package/lib/Typography/TypographyBase.vue.d.ts +12 -44
- package/lib/Upload/UploadPictureCard.vue2.js +1 -1
- package/lib/_shared/icons/IconEyeClose.vue.js +1 -1
- package/lib/_shared/icons/IconEyeClose.vue2.js +1 -1
- package/lib/_shared/icons/IconEyeOpen.vue.js +1 -1
- package/lib/_shared/icons/IconEyeOpen.vue2.js +1 -1
- package/lib/_shared/icons/IconFullScreen.vue.js +1 -1
- package/lib/_shared/icons/IconFullScreen.vue2.js +1 -1
- package/lib/_shared/icons/IconOriginSize.vue.js +1 -1
- package/lib/_shared/icons/IconOriginSize.vue2.js +1 -1
- package/lib/_shared/icons/IconRotateLeft.vue.js +1 -1
- package/lib/_shared/icons/IconRotateLeft.vue2.js +1 -1
- package/lib/_shared/icons/IconRotateRight.vue.js +1 -1
- package/lib/_shared/icons/IconRotateRight.vue2.js +1 -1
- package/lib/_shared/icons/IconSearch.vue.js +1 -1
- package/lib/_shared/icons/IconSearch.vue2.js +1 -1
- package/lib/_shared/icons/IconZoomIn.vue.js +1 -1
- package/lib/_shared/icons/IconZoomIn.vue2.js +1 -1
- package/lib/_shared/icons/IconZoomOut.vue.js +1 -1
- package/lib/_shared/icons/IconZoomOut.vue2.js +1 -1
- package/lib/index.d.ts +9 -9
- package/lib/index.js +1 -1
- package/lib/style.css +1 -1
- package/package.json +1 -1
- package/es/Input/InputSuffix.vue.d.ts +0 -31
- package/es/Input/InputSuffix.vue.js +0 -58
- package/es/Input/InputSuffix.vue3.js +0 -5
- package/lib/Input/InputSuffix.vue.d.ts +0 -31
- package/lib/Input/InputSuffix.vue.js +0 -1
package/lib/Input/Input.vue.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue");require("../node_modules/b-tween/dist/b-tween.es.js"),require("../node_modules/dayjs/dayjs.min.js"),require("../node_modules/tinycolor2/esm/tinycolor.js"),require("../node_modules/dayjs/plugin/duration.js"),require("../node_modules/dayjs/plugin/toObject.js"),require("../node_modules/dayjs/plugin/isSameOrAfter.js"),require("../node_modules/dayjs/plugin/isSameOrBefore.js"),require("../_shared/utils/dom.js");const t=require("../_shared/utils/global-config.js")
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue");require("../node_modules/b-tween/dist/b-tween.es.js"),require("../node_modules/dayjs/dayjs.min.js"),require("../node_modules/tinycolor2/esm/tinycolor.js"),require("../node_modules/dayjs/plugin/duration.js"),require("../node_modules/dayjs/plugin/toObject.js"),require("../node_modules/dayjs/plugin/isSameOrAfter.js"),require("../node_modules/dayjs/plugin/isSameOrBefore.js"),require("../_shared/utils/dom.js");const t=require("../_shared/utils/global-config.js");require("../_shared/utils/locale.js"),require("../_shared/utils/time.js");const o=require("./hooks/useLimitedInput.js"),n=;/* empty css */;/* empty css */const r=;/* empty css */,/* empty css */;/* empty css */const l=["value","disabled","readonly","placeholder"],s={key:0,class:"yc-input-word-limit"},u=e.defineComponent({name:"Input",__name:"Input",props:{modelValue:{default:void 0},defaultValue:{default:""},size:{default:void 0},allowClear:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},error:{type:Boolean,default:void 0},placeholder:{default:""},maxLength:{default:void 0},wordLength:{type:Function,default:e=>e.length},wordSlice:{type:Function,default:(e,t)=>e.slice(0,t)},showWordLimit:{type:Boolean,default:!1},inputAttrs:{default:()=>({})},showInput:{type:Boolean,default:!1}},emits:["update:modelValue","input","change","pressEnter","keydown","clear","focus","blur"],setup(u,{expose:a,emit:d}){const i=e.useSlots(),c=u,p=d,{size:f}=t.getGlobalConfig(c),m=e.ref(),{computedValue:y,showWordLimit:h,showClearBtn:k,curLength:w,maxLength:v,error:b,recordCursor:C,setCursor:_,handleInput:j,handleComposition:B}=o.default({props:c,emits:p,inputRef:m}),g=async(e,t)=>{switch(e){case"input":j(t);break;case"change":p("change",y.value,t);break;case"focus":case"blur":p(e,t);break;case"clear":y.value="",p("clear",t);break;case"keydown":{const e=t;p("keydown",e),"Enter"==e.key&&p("pressEnter",e)}}};return a({setCursor:_,recordCursor:C,focus(){var e;null==(e=m.value)||e.focus()},blur(){var e;null==(e=m.value)||e.blur()},getInputRef:()=>m.value}),(t,o)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["yc-input-outer",`yc-input-size-${e.unref(f)}`,{"yc-input-disabled":t.disabled,"yc-input-error":e.unref(b),"yc-input-has-prepend":i.prepend,"yc-input-has-append":i.append}])},[i.prepend?(e.openBlock(),e.createBlock(e.unref(r.default),{key:0,class:"yc-input-prepend"},{default:e.withCtx(()=>[e.renderSlot(t.$slots,"prepend")]),_:3})):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["yc-input-wrapper",{"yc-input-wrapper-disabled":t.disabled}])},[i.prefix?(e.openBlock(),e.createBlock(e.unref(r.default),{key:0,class:"yc-input-prefix"},{default:e.withCtx(()=>[e.renderSlot(t.$slots,"prefix")]),_:3})):e.createCommentVNode("",!0),e.withDirectives(e.createElementVNode("input",e.mergeProps({value:e.unref(y),disabled:t.disabled,readonly:t.readonly,placeholder:t.placeholder,type:"text"},t.inputAttrs,{class:"yc-input",ref_key:"inputRef",ref:m,onInput:o[0]||(o[0]=e=>g("input",e)),onChange:o[1]||(o[1]=e=>g("change",e)),onCompositionstart:o[2]||(o[2]=(...t)=>e.unref(B)&&e.unref(B)(...t)),onCompositionupdate:o[3]||(o[3]=(...t)=>e.unref(B)&&e.unref(B)(...t)),onCompositionend:o[4]||(o[4]=(...t)=>e.unref(B)&&e.unref(B)(...t)),onFocus:o[5]||(o[5]=e=>g("focus",e)),onBlur:o[6]||(o[6]=e=>g("blur",e)),onKeydown:o[7]||(o[7]=e.withKeys(e=>g("keydown",e),["enter"]))}),null,16,l),[[e.vShow,!i.label||t.showInput]]),i.label?e.withDirectives((e.openBlock(),e.createBlock(e.unref(r.default),{key:1,class:"yc-input text-ellipsis"},{default:e.withCtx(()=>[e.renderSlot(t.$slots,"label")]),_:3},512)),[[e.vShow,!t.showInput]]):e.createCommentVNode("",!0),e.unref(k)?(e.openBlock(),e.createBlock(e.unref(n.default),{key:2,class:"yc-input-clear-button",onClick:o[8]||(o[8]=e=>g("clear",e))})):e.createCommentVNode("",!0),e.createVNode(e.unref(r.default),{class:"yc-input-suffix"},{default:e.withCtx(()=>[e.unref(h)?(e.openBlock(),e.createElementBlock("div",s,e.toDisplayString(e.unref(w))+"/"+e.toDisplayString(e.unref(v)),1)):e.createCommentVNode("",!0),e.renderSlot(t.$slots,"extra"),e.renderSlot(t.$slots,"suffix")]),_:3})],2),i.append?(e.openBlock(),e.createBlock(e.unref(r.default),{key:1,class:"yc-input-append"},{default:e.withCtx(()=>[e.renderSlot(t.$slots,"append")]),_:3})):e.createCommentVNode("",!0)],2))}});exports.default=u;
|
@@ -0,0 +1,309 @@
|
|
1
|
+
import { InputPasswordProps } from './type';
|
2
|
+
declare function __VLS_template(): {
|
3
|
+
attrs: Partial<{}>;
|
4
|
+
slots: {
|
5
|
+
prepend?(_: {}): any;
|
6
|
+
append?(_: {}): any;
|
7
|
+
prefix?(_: {}): any;
|
8
|
+
suffix?(_: {}): any;
|
9
|
+
};
|
10
|
+
refs: {
|
11
|
+
inputRef: ({
|
12
|
+
$: import('vue').ComponentInternalInstance;
|
13
|
+
$data: {};
|
14
|
+
$props: {
|
15
|
+
readonly modelValue?: string | undefined;
|
16
|
+
readonly defaultValue?: string | undefined;
|
17
|
+
readonly size?: import('..').Size | undefined;
|
18
|
+
readonly allowClear?: boolean | undefined;
|
19
|
+
readonly disabled?: boolean | undefined;
|
20
|
+
readonly readonly?: boolean | undefined;
|
21
|
+
readonly error?: boolean | undefined;
|
22
|
+
readonly placeholder?: string | undefined;
|
23
|
+
readonly maxLength?: import('./type').MaxLength | undefined;
|
24
|
+
readonly wordLength?: import('./type').WordLength | undefined;
|
25
|
+
readonly wordSlice?: import('./type').WordSlice | undefined;
|
26
|
+
readonly showWordLimit?: boolean | undefined;
|
27
|
+
readonly inputAttrs?: import('..').RecordType | undefined;
|
28
|
+
readonly showInput?: boolean | undefined;
|
29
|
+
readonly onChange?: ((value: string, ev: Event) => any) | undefined;
|
30
|
+
readonly onFocus?: ((ev: FocusEvent) => any) | undefined;
|
31
|
+
readonly onClear?: ((ev: MouseEvent) => any) | undefined;
|
32
|
+
readonly onBlur?: ((ev: FocusEvent) => any) | undefined;
|
33
|
+
readonly onInput?: ((value: string, ev: Event) => any) | undefined;
|
34
|
+
readonly onKeydown?: ((ev: KeyboardEvent) => any) | undefined;
|
35
|
+
readonly "onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
36
|
+
readonly onPressEnter?: ((ev: KeyboardEvent) => any) | undefined;
|
37
|
+
} & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps;
|
38
|
+
$attrs: {
|
39
|
+
[x: string]: unknown;
|
40
|
+
};
|
41
|
+
$refs: {
|
42
|
+
[x: string]: unknown;
|
43
|
+
} & {
|
44
|
+
inputRef: HTMLInputElement;
|
45
|
+
};
|
46
|
+
$slots: Readonly<{
|
47
|
+
[name: string]: import('vue').Slot<any> | undefined;
|
48
|
+
}>;
|
49
|
+
$root: import('vue').ComponentPublicInstance | null;
|
50
|
+
$parent: import('vue').ComponentPublicInstance | null;
|
51
|
+
$host: Element | null;
|
52
|
+
$emit: ((event: "change", value: string, ev: Event) => void) & ((event: "focus", ev: FocusEvent) => void) & ((event: "clear", ev: MouseEvent) => void) & ((event: "blur", ev: FocusEvent) => void) & ((event: "input", value: string, ev: Event) => void) & ((event: "keydown", ev: KeyboardEvent) => void) & ((event: "update:modelValue", value: string) => void) & ((event: "pressEnter", ev: KeyboardEvent) => void);
|
53
|
+
$el: HTMLDivElement;
|
54
|
+
$options: import('vue').ComponentOptionsBase<Readonly<import('./type').InputProps> & Readonly<{
|
55
|
+
onChange?: ((value: string, ev: Event) => any) | undefined;
|
56
|
+
onFocus?: ((ev: FocusEvent) => any) | undefined;
|
57
|
+
onClear?: ((ev: MouseEvent) => any) | undefined;
|
58
|
+
onBlur?: ((ev: FocusEvent) => any) | undefined;
|
59
|
+
onInput?: ((value: string, ev: Event) => any) | undefined;
|
60
|
+
onKeydown?: ((ev: KeyboardEvent) => any) | undefined;
|
61
|
+
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
62
|
+
onPressEnter?: ((ev: KeyboardEvent) => any) | undefined;
|
63
|
+
}>, {
|
64
|
+
focus(): void;
|
65
|
+
blur(): void;
|
66
|
+
getInputRef(): HTMLInputElement;
|
67
|
+
setCursor?: () => void;
|
68
|
+
recordCursor?: () => void;
|
69
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
|
70
|
+
change: (value: string, ev: Event) => any;
|
71
|
+
focus: (ev: FocusEvent) => any;
|
72
|
+
clear: (ev: MouseEvent) => any;
|
73
|
+
blur: (ev: FocusEvent) => any;
|
74
|
+
input: (value: string, ev: Event) => any;
|
75
|
+
keydown: (ev: KeyboardEvent) => any;
|
76
|
+
"update:modelValue": (value: string) => any;
|
77
|
+
pressEnter: (ev: KeyboardEvent) => any;
|
78
|
+
}, string, {
|
79
|
+
error: boolean;
|
80
|
+
size: import('..').Size;
|
81
|
+
disabled: boolean;
|
82
|
+
placeholder: string;
|
83
|
+
modelValue: string;
|
84
|
+
defaultValue: string;
|
85
|
+
maxLength: import('./type').MaxLength;
|
86
|
+
showWordLimit: boolean;
|
87
|
+
allowClear: boolean;
|
88
|
+
readonly: boolean;
|
89
|
+
wordLength: import('./type').WordLength;
|
90
|
+
wordSlice: import('./type').WordSlice;
|
91
|
+
inputAttrs: import('..').RecordType;
|
92
|
+
showInput: boolean;
|
93
|
+
}, {}, string, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, import('vue').ComponentProvideOptions> & {
|
94
|
+
beforeCreate?: (() => void) | (() => void)[];
|
95
|
+
created?: (() => void) | (() => void)[];
|
96
|
+
beforeMount?: (() => void) | (() => void)[];
|
97
|
+
mounted?: (() => void) | (() => void)[];
|
98
|
+
beforeUpdate?: (() => void) | (() => void)[];
|
99
|
+
updated?: (() => void) | (() => void)[];
|
100
|
+
activated?: (() => void) | (() => void)[];
|
101
|
+
deactivated?: (() => void) | (() => void)[];
|
102
|
+
beforeDestroy?: (() => void) | (() => void)[];
|
103
|
+
beforeUnmount?: (() => void) | (() => void)[];
|
104
|
+
destroyed?: (() => void) | (() => void)[];
|
105
|
+
unmounted?: (() => void) | (() => void)[];
|
106
|
+
renderTracked?: ((e: import('vue').DebuggerEvent) => void) | ((e: import('vue').DebuggerEvent) => void)[];
|
107
|
+
renderTriggered?: ((e: import('vue').DebuggerEvent) => void) | ((e: import('vue').DebuggerEvent) => void)[];
|
108
|
+
errorCaptured?: ((err: unknown, instance: import('vue').ComponentPublicInstance | null, info: string) => boolean | void) | ((err: unknown, instance: import('vue').ComponentPublicInstance | null, info: string) => boolean | void)[];
|
109
|
+
};
|
110
|
+
$forceUpdate: () => void;
|
111
|
+
$nextTick: typeof import('vue').nextTick;
|
112
|
+
$watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (...args: [R, R, import('@vue/reactivity').OnCleanup]) => any : (...args: [any, any, import('@vue/reactivity').OnCleanup]) => any, options?: import('vue').WatchOptions): import('vue').WatchStopHandle;
|
113
|
+
} & Readonly<{
|
114
|
+
error: boolean;
|
115
|
+
size: import('..').Size;
|
116
|
+
disabled: boolean;
|
117
|
+
placeholder: string;
|
118
|
+
modelValue: string;
|
119
|
+
defaultValue: string;
|
120
|
+
maxLength: import('./type').MaxLength;
|
121
|
+
showWordLimit: boolean;
|
122
|
+
allowClear: boolean;
|
123
|
+
readonly: boolean;
|
124
|
+
wordLength: import('./type').WordLength;
|
125
|
+
wordSlice: import('./type').WordSlice;
|
126
|
+
inputAttrs: import('..').RecordType;
|
127
|
+
showInput: boolean;
|
128
|
+
}> & Omit<Readonly<import('./type').InputProps> & Readonly<{
|
129
|
+
onChange?: ((value: string, ev: Event) => any) | undefined;
|
130
|
+
onFocus?: ((ev: FocusEvent) => any) | undefined;
|
131
|
+
onClear?: ((ev: MouseEvent) => any) | undefined;
|
132
|
+
onBlur?: ((ev: FocusEvent) => any) | undefined;
|
133
|
+
onInput?: ((value: string, ev: Event) => any) | undefined;
|
134
|
+
onKeydown?: ((ev: KeyboardEvent) => any) | undefined;
|
135
|
+
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
136
|
+
onPressEnter?: ((ev: KeyboardEvent) => any) | undefined;
|
137
|
+
}>, "focus" | "blur" | "setCursor" | "recordCursor" | "getInputRef" | ("error" | "size" | "disabled" | "placeholder" | "modelValue" | "defaultValue" | "maxLength" | "showWordLimit" | "allowClear" | "readonly" | "wordLength" | "wordSlice" | "inputAttrs" | "showInput")> & import('vue').ShallowUnwrapRef<{
|
138
|
+
focus(): void;
|
139
|
+
blur(): void;
|
140
|
+
getInputRef(): HTMLInputElement;
|
141
|
+
setCursor?: () => void;
|
142
|
+
recordCursor?: () => void;
|
143
|
+
}> & {} & import('@vue/runtime-core').ComponentCustomProperties & {} & {
|
144
|
+
$slots: any;
|
145
|
+
}) | null;
|
146
|
+
};
|
147
|
+
rootEl: HTMLDivElement;
|
148
|
+
};
|
149
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
150
|
+
declare const __VLS_component: import('vue').DefineComponent<InputPasswordProps, {
|
151
|
+
focus(): void;
|
152
|
+
blur(): void;
|
153
|
+
getInputRef(): HTMLInputElement;
|
154
|
+
setCursor?: () => void;
|
155
|
+
recordCursor?: () => void;
|
156
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
|
157
|
+
"update:visibility": (value: boolean) => any;
|
158
|
+
"visibility-change": (value: boolean) => any;
|
159
|
+
}, string, import('vue').PublicProps, Readonly<InputPasswordProps> & Readonly<{
|
160
|
+
"onUpdate:visibility"?: ((value: boolean) => any) | undefined;
|
161
|
+
"onVisibility-change"?: ((value: boolean) => any) | undefined;
|
162
|
+
}>, {
|
163
|
+
visibility: boolean;
|
164
|
+
defaultVisibility: boolean;
|
165
|
+
invisibleButton: boolean;
|
166
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
167
|
+
inputRef: ({
|
168
|
+
$: import('vue').ComponentInternalInstance;
|
169
|
+
$data: {};
|
170
|
+
$props: {
|
171
|
+
readonly modelValue?: string | undefined;
|
172
|
+
readonly defaultValue?: string | undefined;
|
173
|
+
readonly size?: import('..').Size | undefined;
|
174
|
+
readonly allowClear?: boolean | undefined;
|
175
|
+
readonly disabled?: boolean | undefined;
|
176
|
+
readonly readonly?: boolean | undefined;
|
177
|
+
readonly error?: boolean | undefined;
|
178
|
+
readonly placeholder?: string | undefined;
|
179
|
+
readonly maxLength?: import('./type').MaxLength | undefined;
|
180
|
+
readonly wordLength?: import('./type').WordLength | undefined;
|
181
|
+
readonly wordSlice?: import('./type').WordSlice | undefined;
|
182
|
+
readonly showWordLimit?: boolean | undefined;
|
183
|
+
readonly inputAttrs?: import('..').RecordType | undefined;
|
184
|
+
readonly showInput?: boolean | undefined;
|
185
|
+
readonly onChange?: ((value: string, ev: Event) => any) | undefined;
|
186
|
+
readonly onFocus?: ((ev: FocusEvent) => any) | undefined;
|
187
|
+
readonly onClear?: ((ev: MouseEvent) => any) | undefined;
|
188
|
+
readonly onBlur?: ((ev: FocusEvent) => any) | undefined;
|
189
|
+
readonly onInput?: ((value: string, ev: Event) => any) | undefined;
|
190
|
+
readonly onKeydown?: ((ev: KeyboardEvent) => any) | undefined;
|
191
|
+
readonly "onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
192
|
+
readonly onPressEnter?: ((ev: KeyboardEvent) => any) | undefined;
|
193
|
+
} & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps;
|
194
|
+
$attrs: {
|
195
|
+
[x: string]: unknown;
|
196
|
+
};
|
197
|
+
$refs: {
|
198
|
+
[x: string]: unknown;
|
199
|
+
} & {
|
200
|
+
inputRef: HTMLInputElement;
|
201
|
+
};
|
202
|
+
$slots: Readonly<{
|
203
|
+
[name: string]: import('vue').Slot<any> | undefined;
|
204
|
+
}>;
|
205
|
+
$root: import('vue').ComponentPublicInstance | null;
|
206
|
+
$parent: import('vue').ComponentPublicInstance | null;
|
207
|
+
$host: Element | null;
|
208
|
+
$emit: ((event: "change", value: string, ev: Event) => void) & ((event: "focus", ev: FocusEvent) => void) & ((event: "clear", ev: MouseEvent) => void) & ((event: "blur", ev: FocusEvent) => void) & ((event: "input", value: string, ev: Event) => void) & ((event: "keydown", ev: KeyboardEvent) => void) & ((event: "update:modelValue", value: string) => void) & ((event: "pressEnter", ev: KeyboardEvent) => void);
|
209
|
+
$el: HTMLDivElement;
|
210
|
+
$options: import('vue').ComponentOptionsBase<Readonly<import('./type').InputProps> & Readonly<{
|
211
|
+
onChange?: ((value: string, ev: Event) => any) | undefined;
|
212
|
+
onFocus?: ((ev: FocusEvent) => any) | undefined;
|
213
|
+
onClear?: ((ev: MouseEvent) => any) | undefined;
|
214
|
+
onBlur?: ((ev: FocusEvent) => any) | undefined;
|
215
|
+
onInput?: ((value: string, ev: Event) => any) | undefined;
|
216
|
+
onKeydown?: ((ev: KeyboardEvent) => any) | undefined;
|
217
|
+
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
218
|
+
onPressEnter?: ((ev: KeyboardEvent) => any) | undefined;
|
219
|
+
}>, {
|
220
|
+
focus(): void;
|
221
|
+
blur(): void;
|
222
|
+
getInputRef(): HTMLInputElement;
|
223
|
+
setCursor?: () => void;
|
224
|
+
recordCursor?: () => void;
|
225
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
|
226
|
+
change: (value: string, ev: Event) => any;
|
227
|
+
focus: (ev: FocusEvent) => any;
|
228
|
+
clear: (ev: MouseEvent) => any;
|
229
|
+
blur: (ev: FocusEvent) => any;
|
230
|
+
input: (value: string, ev: Event) => any;
|
231
|
+
keydown: (ev: KeyboardEvent) => any;
|
232
|
+
"update:modelValue": (value: string) => any;
|
233
|
+
pressEnter: (ev: KeyboardEvent) => any;
|
234
|
+
}, string, {
|
235
|
+
error: boolean;
|
236
|
+
size: import('..').Size;
|
237
|
+
disabled: boolean;
|
238
|
+
placeholder: string;
|
239
|
+
modelValue: string;
|
240
|
+
defaultValue: string;
|
241
|
+
maxLength: import('./type').MaxLength;
|
242
|
+
showWordLimit: boolean;
|
243
|
+
allowClear: boolean;
|
244
|
+
readonly: boolean;
|
245
|
+
wordLength: import('./type').WordLength;
|
246
|
+
wordSlice: import('./type').WordSlice;
|
247
|
+
inputAttrs: import('..').RecordType;
|
248
|
+
showInput: boolean;
|
249
|
+
}, {}, string, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, import('vue').ComponentProvideOptions> & {
|
250
|
+
beforeCreate?: (() => void) | (() => void)[];
|
251
|
+
created?: (() => void) | (() => void)[];
|
252
|
+
beforeMount?: (() => void) | (() => void)[];
|
253
|
+
mounted?: (() => void) | (() => void)[];
|
254
|
+
beforeUpdate?: (() => void) | (() => void)[];
|
255
|
+
updated?: (() => void) | (() => void)[];
|
256
|
+
activated?: (() => void) | (() => void)[];
|
257
|
+
deactivated?: (() => void) | (() => void)[];
|
258
|
+
beforeDestroy?: (() => void) | (() => void)[];
|
259
|
+
beforeUnmount?: (() => void) | (() => void)[];
|
260
|
+
destroyed?: (() => void) | (() => void)[];
|
261
|
+
unmounted?: (() => void) | (() => void)[];
|
262
|
+
renderTracked?: ((e: import('vue').DebuggerEvent) => void) | ((e: import('vue').DebuggerEvent) => void)[];
|
263
|
+
renderTriggered?: ((e: import('vue').DebuggerEvent) => void) | ((e: import('vue').DebuggerEvent) => void)[];
|
264
|
+
errorCaptured?: ((err: unknown, instance: import('vue').ComponentPublicInstance | null, info: string) => boolean | void) | ((err: unknown, instance: import('vue').ComponentPublicInstance | null, info: string) => boolean | void)[];
|
265
|
+
};
|
266
|
+
$forceUpdate: () => void;
|
267
|
+
$nextTick: typeof import('vue').nextTick;
|
268
|
+
$watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (...args: [R, R, import('@vue/reactivity').OnCleanup]) => any : (...args: [any, any, import('@vue/reactivity').OnCleanup]) => any, options?: import('vue').WatchOptions): import('vue').WatchStopHandle;
|
269
|
+
} & Readonly<{
|
270
|
+
error: boolean;
|
271
|
+
size: import('..').Size;
|
272
|
+
disabled: boolean;
|
273
|
+
placeholder: string;
|
274
|
+
modelValue: string;
|
275
|
+
defaultValue: string;
|
276
|
+
maxLength: import('./type').MaxLength;
|
277
|
+
showWordLimit: boolean;
|
278
|
+
allowClear: boolean;
|
279
|
+
readonly: boolean;
|
280
|
+
wordLength: import('./type').WordLength;
|
281
|
+
wordSlice: import('./type').WordSlice;
|
282
|
+
inputAttrs: import('..').RecordType;
|
283
|
+
showInput: boolean;
|
284
|
+
}> & Omit<Readonly<import('./type').InputProps> & Readonly<{
|
285
|
+
onChange?: ((value: string, ev: Event) => any) | undefined;
|
286
|
+
onFocus?: ((ev: FocusEvent) => any) | undefined;
|
287
|
+
onClear?: ((ev: MouseEvent) => any) | undefined;
|
288
|
+
onBlur?: ((ev: FocusEvent) => any) | undefined;
|
289
|
+
onInput?: ((value: string, ev: Event) => any) | undefined;
|
290
|
+
onKeydown?: ((ev: KeyboardEvent) => any) | undefined;
|
291
|
+
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
292
|
+
onPressEnter?: ((ev: KeyboardEvent) => any) | undefined;
|
293
|
+
}>, "focus" | "blur" | "setCursor" | "recordCursor" | "getInputRef" | ("error" | "size" | "disabled" | "placeholder" | "modelValue" | "defaultValue" | "maxLength" | "showWordLimit" | "allowClear" | "readonly" | "wordLength" | "wordSlice" | "inputAttrs" | "showInput")> & import('vue').ShallowUnwrapRef<{
|
294
|
+
focus(): void;
|
295
|
+
blur(): void;
|
296
|
+
getInputRef(): HTMLInputElement;
|
297
|
+
setCursor?: () => void;
|
298
|
+
recordCursor?: () => void;
|
299
|
+
}> & {} & import('@vue/runtime-core').ComponentCustomProperties & {} & {
|
300
|
+
$slots: any;
|
301
|
+
}) | null;
|
302
|
+
}, HTMLDivElement>;
|
303
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
304
|
+
export default _default;
|
305
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
306
|
+
new (): {
|
307
|
+
$slots: S;
|
308
|
+
};
|
309
|
+
};
|
@@ -0,0 +1 @@
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue");require("../node_modules/b-tween/dist/b-tween.es.js"),require("../node_modules/dayjs/dayjs.min.js"),require("../node_modules/tinycolor2/esm/tinycolor.js"),require("../node_modules/dayjs/plugin/duration.js"),require("../node_modules/dayjs/plugin/toObject.js"),require("../node_modules/dayjs/plugin/isSameOrAfter.js"),require("../node_modules/dayjs/plugin/isSameOrBefore.js");const t=require("../_shared/utils/dom.js"),s=require("../_shared/utils/hooks.js");require("../_shared/utils/locale.js"),require("../_shared/utils/time.js");const r=;/* empty css */,/* empty css */,/* empty css */;/* empty css */const o=require("../_shared/icons/IconEyeClose.vue.js"),i=require("../_shared/icons/IconEyeOpen.vue.js"),n=require("./Input.vue.js");;/* empty css */const u=e.defineComponent({name:"InputPassword",__name:"InputPassword",props:{visibility:{type:Boolean,default:void 0},defaultVisibility:{type:Boolean,default:!1},invisibleButton:{type:Boolean,default:!0}},emits:["update:visibility","visibility-change"],setup(u,{expose:l,emit:a}){const d=u,p=a,{visibility:c,defaultVisibility:f}=e.toRefs(d),v=s.useControlValue(c,f.value,e=>{p("update:visibility",e),p("visibility-change",e)}),y=e.ref(),m=async()=>{var e,s,r,o;null==(s=null==(e=y.value)?void 0:e.recordCursor)||s.call(e),await t.sleep(0),v.value=!v.value,null==(o=null==(r=y.value)?void 0:r.setCursor)||o.call(r)};return l({focus(){var e;null==(e=y.value)||e.focus()},blur(){var e;null==(e=y.value)||e.blur()},getInputRef(){var e;return null==(e=y.value)?void 0:e.getInputRef()}}),(t,s)=>(e.openBlock(),e.createBlock(n.default,e.mergeProps(t.$attrs,{"input-attrs":{type:e.unref(v)?"text":"password"},ref_key:"inputRef",ref:y}),e.createSlots({extra:e.withCtx(()=>[t.invisibleButton?(e.openBlock(),e.createBlock(e.unref(r.default),{key:0,size:14,onClick:m},{default:e.withCtx(()=>[e.unref(v)?(e.openBlock(),e.createBlock(e.unref(i.default),{key:0})):(e.openBlock(),e.createBlock(e.unref(o.default),{key:1}))]),_:1})):e.createCommentVNode("",!0)]),_:2},[t.$slots.prepend?{name:"prepend",fn:e.withCtx(()=>[e.renderSlot(t.$slots,"prepend")]),key:"0"}:void 0,t.$slots.append?{name:"append",fn:e.withCtx(()=>[e.renderSlot(t.$slots,"append")]),key:"1"}:void 0,t.$slots.prefix?{name:"prefix",fn:e.withCtx(()=>[e.renderSlot(t.$slots,"prefix")]),key:"2"}:void 0,t.$slots.suffix?{name:"suffix",fn:e.withCtx(()=>[e.renderSlot(t.$slots,"suffix")]),key:"3"}:void 0]),1040,["input-attrs"]))}});exports.default=u;
|
@@ -1 +1 @@
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("./
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("./InputPassword.vue.js");exports.default=e.default;
|