fix(api): use bcrypt directly instead of passlib for compatibility

This commit is contained in:
bwstudio
2026-05-21 22:18:36 +08:00
parent 7f51d200f1
commit 4651781bc3
23511 changed files with 2587254 additions and 8 deletions
@@ -0,0 +1 @@
{"version":3,"file":"useProps.mjs","names":[],"sources":["../../../../../../packages/components/select-v2/src/useProps.ts"],"sourcesContent":["import { ref, watch } from 'vue'\nimport { get, isEqual } from 'lodash-unified'\n\nimport type { SelectV2Props } from './token'\nimport type { Option } from './select.types'\n\nexport interface Props {\n label?: string\n value?: string\n disabled?: string\n options?: string\n}\n\nexport const defaultProps: Required<Props> = {\n label: 'label',\n value: 'value',\n disabled: 'disabled',\n options: 'options',\n}\n\nexport function useProps(props: Pick<SelectV2Props, 'props'>) {\n const aliasProps = ref({ ...defaultProps, ...props.props })\n let cache = { ...props.props }\n\n watch(\n () => props.props,\n (val) => {\n // The props is an object, and its properties may be modified without changing the reference. In this case, the watch values before and after are equal. Here, we compare using the cached previous value.\n if (!isEqual(val, cache)) {\n aliasProps.value = { ...defaultProps, ...val }\n cache = { ...val }\n }\n },\n { deep: true }\n )\n\n const getLabel = (option: Option) => get(option, aliasProps.value.label)\n const getValue = (option: Option) => get(option, aliasProps.value.value)\n const getDisabled = (option: Option) => get(option, aliasProps.value.disabled)\n const getOptions = (option: Option) => get(option, aliasProps.value.options)\n\n return {\n aliasProps,\n getLabel,\n getValue,\n getDisabled,\n getOptions,\n }\n}\n"],"mappings":";;;AAaA,MAAa,eAAgC;CAC3C,OAAO;CACP,OAAO;CACP,UAAU;CACV,SAAS;CACV;AAED,SAAgB,SAAS,OAAqC;CAC5D,MAAM,aAAa,IAAI;EAAE,GAAG;EAAc,GAAG,MAAM;EAAO,CAAC;CAC3D,IAAI,QAAQ,EAAE,GAAG,MAAM,OAAO;CAE9B,YACQ,MAAM,QACX,QAAQ;EAEP,IAAI,CAAC,QAAQ,KAAK,MAAM,EAAE;GACxB,WAAW,QAAQ;IAAE,GAAG;IAAc,GAAG;IAAK;GAC9C,QAAQ,EAAE,GAAG,KAAK;;IAGtB,EAAE,MAAM,MAAM,CACf;CAED,MAAM,YAAY,WAAmB,IAAI,QAAQ,WAAW,MAAM,MAAM;CACxE,MAAM,YAAY,WAAmB,IAAI,QAAQ,WAAW,MAAM,MAAM;CACxE,MAAM,eAAe,WAAmB,IAAI,QAAQ,WAAW,MAAM,SAAS;CAC9E,MAAM,cAAc,WAAmB,IAAI,QAAQ,WAAW,MAAM,QAAQ;CAE5E,OAAO;EACL;EACA;EACA;EACA;EACA;EACD"}