@v-miniapp/ui-react 1.0.59 → 1.0.71
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/_virtual/_cloneBuffer.js +4 -0
- package/dist/_virtual/_commonjsHelpers.js +8 -0
- package/dist/_virtual/_nodeUtil.js +4 -0
- package/dist/_virtual/cloneDeepWith.js +7 -0
- package/dist/_virtual/isBuffer.js +4 -0
- package/dist/_virtual/isObject.js +7 -0
- package/dist/_virtual/isSameOrAfter.js +7 -0
- package/dist/_virtual/isSameOrAfter2.js +4 -0
- package/dist/_virtual/isSameOrBefore.js +7 -0
- package/dist/_virtual/isSameOrBefore2.js +4 -0
- package/dist/_virtual/merge.js +7 -0
- package/dist/_virtual/omit.js +7 -0
- package/dist/_virtual/pick.js +7 -0
- package/dist/_virtual/throttle.js +7 -0
- package/dist/assets/icons/loader.svg.js +5 -0
- package/dist/assets/icons/placeholder.svg.js +5 -0
- package/dist/assets/images/broken-image.svg.js +5 -0
- package/dist/assets/images/default-error.png.js +4 -0
- package/dist/assets/images/image.svg.js +5 -0
- package/dist/components/ai-app/ai-app.d.ts +7 -0
- package/dist/components/ai-app/ai-app.js +20 -0
- package/dist/components/ai-app/index.d.ts +1 -0
- package/dist/components/alert/alert.js +76 -0
- package/dist/components/app/app.d.ts +1 -6
- package/dist/components/app/app.js +78 -0
- package/dist/components/app/app.store.d.ts +6 -0
- package/dist/components/app/app.store.js +8 -0
- package/dist/components/app/bottom-tab-bar-layout/hook.js +36 -0
- package/dist/components/app/bottom-tab-bar-layout/index.js +38 -0
- package/dist/components/app/bottom-tab-bar-layout/store.js +54 -0
- package/dist/components/app/data-theme.js +29 -0
- package/dist/components/app/navigation-bar-layout/hook.js +39 -0
- package/dist/components/app/navigation-bar-layout/index.js +46 -0
- package/dist/components/app/navigation-bar-layout/store.js +60 -0
- package/dist/components/app/page-layout/hook.js +62 -0
- package/dist/components/app/page-layout/index.js +21 -0
- package/dist/components/app/page-layout/store.js +52 -0
- package/dist/components/avatar/avatar.js +79 -0
- package/dist/components/badge/badge.js +40 -0
- package/dist/components/bottom-tab-bar/bottom-tab-bar.js +90 -0
- package/dist/components/button/button.const.js +7 -0
- package/dist/components/button/button.js +62 -0
- package/dist/components/calendar/calendar-range-sheet.js +66 -0
- package/dist/components/calendar/calendar-single-sheet.js +64 -0
- package/dist/components/calendar/calendar.js +16 -0
- package/dist/components/calendar/default-render.js +16 -0
- package/dist/components/calendar/range-picker.js +301 -0
- package/dist/components/calendar/single-picker.js +186 -0
- package/dist/components/calendar/utils.js +25 -0
- package/dist/components/carousel/carousel.js +47 -0
- package/dist/components/carousel/use-carousel.js +54 -0
- package/dist/components/checkbox/check-icon.js +23 -0
- package/dist/components/checkbox/checkbox.js +131 -0
- package/dist/components/checkbox/indeterminate-icon.js +20 -0
- package/dist/components/chip/chip.js +80 -0
- package/dist/components/date-field/date-field-range.js +153 -0
- package/dist/components/date-field/date-field.js +100 -0
- package/dist/components/date-field/input.js +53 -0
- package/dist/components/date-picker/date-picker-base.js +214 -0
- package/dist/components/date-picker/date-picker-item.js +69 -0
- package/dist/components/date-picker/date-picker-sheet.js +54 -0
- package/dist/components/date-picker/date-picker.constant.js +11 -0
- package/dist/components/date-picker/date-picker.js +76 -0
- package/dist/components/date-picker/date-picker.utils.js +58 -0
- package/dist/components/dialog/dialog.js +115 -0
- package/dist/components/dropdown/dropdown-base.js +22 -0
- package/dist/components/dropdown/dropdown.js +148 -0
- package/dist/components/error/error-boundary.js +28 -0
- package/dist/components/error/error.js +25 -0
- package/dist/components/icon/icon-mapping.js +260 -0
- package/dist/components/icon/icon.js +54 -0
- package/dist/components/image/image.js +70 -0
- package/dist/components/index.d.ts +1 -0
- package/dist/components/input-wrapper/input-wrapper.js +153 -0
- package/dist/components/label/label.js +58 -0
- package/dist/components/layout/page-loading.js +39 -0
- package/dist/components/layout/page.js +103 -0
- package/dist/components/list-item/list-item.js +36 -0
- package/dist/components/navigation-bar/navigation-bar.d.ts +1 -4
- package/dist/components/navigation-bar/navigation-bar.js +106 -0
- package/dist/components/number-field/number-field.js +162 -0
- package/dist/components/option-item/option-item.js +56 -0
- package/dist/components/pagination/pagination.js +20 -0
- package/dist/components/pull-to-refresh/pull-to-refresh.js +120 -0
- package/dist/components/radio/radio.js +72 -0
- package/dist/components/rating/rating.js +62 -0
- package/dist/components/rating/star.js +22 -0
- package/dist/components/search-field/search-field.js +40 -0
- package/dist/components/section/section-content.js +10 -0
- package/dist/components/section/section-title.js +32 -0
- package/dist/components/section/section.js +21 -0
- package/dist/components/seo/seo.js +18 -0
- package/dist/components/sheet/sheet-body.js +25 -0
- package/dist/components/sheet/sheet-footer.js +11 -0
- package/dist/components/sheet/sheet-header.js +52 -0
- package/dist/components/sheet/sheet.js +72 -0
- package/dist/components/skeleton/skeleton.js +50 -0
- package/dist/components/switch/switch.js +68 -0
- package/dist/components/tab-bar/tab-bar.js +130 -0
- package/dist/components/tab-bar/tab.js +55 -0
- package/dist/components/text-area/text-area.js +75 -0
- package/dist/components/text-field/text-field.js +63 -0
- package/dist/components/toast/toast-provider.js +45 -0
- package/dist/components/toast/toast.js +66 -0
- package/dist/components/toast/toast.store.js +35 -0
- package/dist/components/tooltip/tooltip.js +43 -0
- package/dist/components/typography/typography.js +28 -0
- package/dist/components/uploader/helper.js +21 -0
- package/dist/components/uploader/uploader.js +93 -0
- package/dist/components/visibility-sensor/visibility-sensor.js +17 -0
- package/dist/docs/ui-react/icon-list-grid.d.ts +1 -0
- package/dist/external/index.js +13357 -13497
- package/dist/external/styles.css +1 -1
- package/dist/hooks/use-custom-icon-event.js +16 -0
- package/dist/hooks/use-settings-changed.js +16 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +139 -7488
- package/dist/locales/en.json.js +30 -0
- package/dist/locales/index.d.ts +2 -0
- package/dist/locales/index.js +10 -0
- package/dist/locales/vi.json.js +30 -0
- package/dist/node_modules/.pnpm/dayjs@1.11.19/node_modules/dayjs/plugin/isSameOrAfter.js +18 -0
- package/dist/node_modules/.pnpm/dayjs@1.11.19/node_modules/dayjs/plugin/isSameOrBefore.js +18 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_DataView.js +12 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_Hash.js +22 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_ListCache.js +22 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_Map.js +12 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_MapCache.js +22 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_Promise.js +12 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_Set.js +12 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_Stack.js +20 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_Symbol.js +11 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_Uint8Array.js +11 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_WeakMap.js +12 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_apply.js +22 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_arrayEach.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_arrayFilter.js +16 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_arrayLikeKeys.js +26 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_arrayMap.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_arrayPush.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_assignMergeValue.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_assignValue.js +16 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_assocIndexOf.js +17 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseAssign.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseAssignIn.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseAssignValue.js +19 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseClone.js +70 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseCreate.js +23 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseFlatten.js +20 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseFor.js +11 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseGet.js +18 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseGetAllKeys.js +16 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseGetTag.js +16 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseHasIn.js +12 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseIsArguments.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseIsMap.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseIsNative.js +22 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseIsSet.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseIsTypedArray.js +17 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseKeys.js +20 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseKeysIn.js +21 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseMerge.js +27 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseMergeDeep.js +38 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_basePick.js +17 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_basePickBy.js +20 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseRest.js +16 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseSet.js +31 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseSetToString.js +20 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseSlice.js +16 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseTimes.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseToString.js +24 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseTrim.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseUnary.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_baseUnset.js +34 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_castPath.js +17 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_cloneArrayBuffer.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_cloneBuffer.js +19 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_cloneDataView.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_cloneRegExp.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_cloneSymbol.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_cloneTypedArray.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_copyArray.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_copyObject.js +21 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_copySymbols.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_copySymbolsIn.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_coreJsData.js +11 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_createAssigner.js +22 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_createBaseFor.js +19 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_customOmitClone.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_defineProperty.js +17 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_flatRest.js +16 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_freeGlobal.js +11 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_getAllKeys.js +16 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_getAllKeysIn.js +16 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_getMapData.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_getNative.js +16 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_getPrototype.js +11 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_getRawTag.js +21 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_getSymbols.js +16 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_getSymbolsIn.js +18 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_getTag.js +33 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_getValue.js +12 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_hasPath.js +26 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_hashClear.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_hashDelete.js +13 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_hashGet.js +19 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_hashHas.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_hashSet.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_initCloneArray.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_initCloneByTag.js +48 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_initCloneObject.js +16 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_isFlattenable.js +16 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_isIndex.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_isIterateeCall.js +20 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_isKey.js +18 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_isKeyable.js +13 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_isMasked.js +17 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_isPrototype.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_listCacheClear.js +12 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_listCacheDelete.js +18 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_listCacheGet.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_listCacheHas.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_listCacheSet.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_mapCacheClear.js +20 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_mapCacheDelete.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_mapCacheGet.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_mapCacheHas.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_mapCacheSet.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_memoizeCapped.js +17 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_nativeCreate.js +11 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_nativeKeys.js +11 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_nativeKeysIn.js +16 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_nodeUtil.js +19 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_objectToString.js +13 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_overArg.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_overRest.js +21 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_parent.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_root.js +11 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_safeGet.js +13 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_setToString.js +12 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_shortOut.js +22 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_stackClear.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_stackDelete.js +13 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_stackGet.js +12 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_stackHas.js +12 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_stackSet.js +23 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_stringToPath.js +16 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_toKey.js +17 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_toSource.js +23 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/_trimmedEndIndex.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/cloneDeepWith.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/constant.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/debounce.js +60 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/eq.js +12 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/flatten.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/hasIn.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/identity.js +12 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/isArguments.js +16 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/isArray.js +10 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/isArrayLike.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/isArrayLikeObject.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/isBuffer.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/isFunction.js +18 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/isLength.js +13 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/isMap.js +13 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/isObject.js +13 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/isObjectLike.js +12 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/isPlainObject.js +22 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/isSet.js +13 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/isSymbol.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/isTypedArray.js +13 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/keys.js +16 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/keysIn.js +16 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/last.js +13 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/memoize.js +23 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/merge.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/now.js +13 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/omit.js +29 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/pick.js +14 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/stubArray.js +12 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/stubFalse.js +12 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/throttle.js +22 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/toNumber.js +28 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/toPlainObject.js +15 -0
- package/dist/node_modules/.pnpm/lodash@4.17.23/node_modules/lodash/toString.js +14 -0
- package/dist/styles.css +1 -1
- package/dist/utils/bound.js +7 -0
- package/dist/utils/can-use-dom.js +4 -0
- package/dist/utils/classname.js +6 -0
- package/dist/utils/colors.gen.js +371 -0
- package/dist/utils/colors.js +8 -0
- package/dist/utils/convert-px.js +14 -0
- package/dist/utils/date.d.ts +2 -1
- package/dist/utils/date.js +9 -0
- package/dist/utils/deep-clone.js +10 -0
- package/dist/utils/dev-log.js +7 -0
- package/dist/utils/get-scroll-parent.js +20 -0
- package/dist/utils/is-dev.js +4 -0
- package/dist/utils/rubberband.js +11 -0
- package/dist/utils/sleep.js +4 -0
- package/dist/utils/supports-passive.js +15 -0
- package/dist/utils/to-css-length.js +6 -0
- package/dist/vsf/choose-image.js +14 -0
- package/dist-storybook/assets/AIApp-C4keJkW8.js +37 -0
- package/dist-storybook/assets/{App-Dp1UG-xp.js → App-BkiRuUOF.js} +1 -1
- package/dist-storybook/assets/Color-6BZIO3FS-EdXZe4iv.js +1 -0
- package/dist-storybook/assets/{DEEPLINK-cjgFMuRJ.js → DEEPLINK-CvpIbZVm.js} +1 -1
- package/dist-storybook/assets/DocsRenderer-LL677BLK-Ch7ovClC.js +2 -0
- package/dist-storybook/assets/{EVENTS-BY66PjI7.js → EVENTS-Bnl2ehlm.js} +1 -1
- package/dist-storybook/assets/{GETTING_STARTED-BiQMvjvo.js → GETTING_STARTED-BYcN9hg3.js} +1 -1
- package/dist-storybook/assets/{GETTING_STARTED-580o-9Mx.js → GETTING_STARTED-BmHWFQQE.js} +1 -1
- package/dist-storybook/assets/GETTING_STARTED-C1AOB25Z.js +45 -0
- package/dist-storybook/assets/{GETTING_STARTED-CIVMqKZW.js → GETTING_STARTED-CBY9dL2_.js} +1 -1
- package/dist-storybook/assets/ICON-BaZgXbtw.js +6 -0
- package/dist-storybook/assets/ICON-CT1pTB1A.js +6 -0
- package/dist-storybook/assets/{INFINITE_SCROLL-BbeR5HeP.js → INFINITE_SCROLL-BJeWhgO7.js} +1 -1
- package/dist-storybook/assets/{LocalesProvider-CMlmwAyY.js → LocalesProvider-CQEwtoq3.js} +1 -1
- package/dist-storybook/assets/{MIGRATE_DARKMODE_TO_THEME-CBDyZyg2.js → MIGRATE_DARKMODE_TO_THEME-DCxXgvQC.js} +1 -1
- package/dist-storybook/assets/{MIGRATION_GUIDE-FZyRWI-B.js → MIGRATION_GUIDE-BN_V-xNj.js} +1 -1
- package/dist-storybook/assets/OVERVIEW-AI-CLWBzviY.js +35 -0
- package/dist-storybook/assets/{OVERVIEW-C9_6gX5Q.js → OVERVIEW-Byly3lQV.js} +1 -1
- package/dist-storybook/assets/{Router-B5U8bubH.js → Router-CO6rjSXr.js} +1 -1
- package/dist-storybook/assets/{TAILWIND_INTEGRATION-BJdy5DAv.js → TAILWIND_INTEGRATION-CpN4_fSu.js} +1 -1
- package/dist-storybook/assets/{THEME-CRbvH7KT.js → THEME-B9Y39f9D.js} +1 -1
- package/dist-storybook/assets/WithTooltip-65CFNBJE-D6J_7FjK.js +9 -0
- package/dist-storybook/assets/{alert.stories-D0X5wUHk.js → alert.stories-CUItfPLn.js} +12 -12
- package/dist-storybook/assets/app.store-BJVKVv1J.js +1 -0
- package/dist-storybook/assets/avatar.stories-8_vV7Bb0.js +136 -0
- package/dist-storybook/assets/{axe-BHGdSCoA.js → axe-4EaTvypG.js} +13 -13
- package/dist-storybook/assets/badge-Gh2kTOE3.js +1 -0
- package/dist-storybook/assets/{badge.stories-BEFNaUA1.js → badge.stories-BXGAtgaV.js} +3 -3
- package/dist-storybook/assets/blocks-CB7UwFa4.js +758 -0
- package/dist-storybook/assets/bottom-tab-bar.stories-OrY-k1sb.js +280 -0
- package/dist-storybook/assets/button-BLW8SOpg.js +1 -0
- package/dist-storybook/assets/{button.stories-DgYDJ6x7.js → button.stories--0kpp_af.js} +3 -3
- package/dist-storybook/assets/calendar-ySr-9cXG.js +1 -0
- package/dist-storybook/assets/{calendar.stories-IVvRAjWN.js → calendar.stories-4MQj1nsX.js} +1 -1
- package/dist-storybook/assets/carousel.stories-CMtljvBR.js +253 -0
- package/dist-storybook/assets/checkbox.stories-xYjsVg2X.js +201 -0
- package/dist-storybook/assets/{chip.stories-D7E6fdiV.js → chip.stories-DYEfUGq3.js} +12 -12
- package/dist-storybook/assets/classname-Bl5epEs-.js +1 -0
- package/dist-storybook/assets/client-CN8vOzuD.js +9 -0
- package/dist-storybook/assets/{date-B3PFMb6s.js → date-DWIyMGld.js} +1 -1
- package/dist-storybook/assets/date-field.stories-5Tlzdpvr.js +129 -0
- package/dist-storybook/assets/date-picker-DeB43YU4.js +1 -0
- package/dist-storybook/assets/{date-picker.stories-CIFgk4q_.js → date-picker.stories-Shn-MmVG.js} +1 -1
- package/dist-storybook/assets/dialog.stories-DeNKN0oJ.js +212 -0
- package/dist-storybook/assets/dropdown.stories-Bqmu2_KM.js +449 -0
- package/dist-storybook/assets/{embla-carousel-react.esm-5D5fs7OQ.js → embla-carousel-react.esm-DOEAp-w3.js} +1 -1
- package/dist-storybook/assets/{en-Cs9O0XWn.js → en-IjeCvZ5U.js} +1 -1
- package/dist-storybook/assets/formatter-EIJCOSYU-DZLV30KU.js +1 -0
- package/dist-storybook/assets/icon-Cc9W858e.js +1 -0
- package/dist-storybook/assets/icon-list-grid-CSnpdoAW.js +1 -0
- package/dist-storybook/assets/{icon.stories-DWwbUUY-.js → icon.stories-DE484rTd.js} +3 -3
- package/dist-storybook/assets/iframe-BBKyXin_.css +1 -0
- package/dist-storybook/assets/iframe-Crg_lbde.js +1119 -0
- package/dist-storybook/assets/image-CB4oeTy-.js +9 -0
- package/dist-storybook/assets/{image.stories-BhZU057W.js → image.stories-BlYIb_Qu.js} +1 -1
- package/dist-storybook/assets/index-B24pfkXD.js +1 -0
- package/dist-storybook/assets/{index-cMNObl2z.js → index-CdnALcTP.js} +1 -1
- package/dist-storybook/assets/{index-EGt7xBnA.js → index-hDlmuyu2.js} +1 -1
- package/dist-storybook/assets/input-wrapper-Gd3QJKqj.js +1 -0
- package/dist-storybook/assets/label-zfqCJTGJ.js +22 -0
- package/dist-storybook/assets/{label.stories-CXJjdYf_.js → label.stories-C-MVt-cu.js} +3 -3
- package/dist-storybook/assets/matchers-5TDFFDYO-HJu_DfWo.js +14 -0
- package/dist-storybook/assets/navigation-bar.stories-CZ-y3eDE.js +136 -0
- package/dist-storybook/assets/number-field.stories-BA0FySSU.js +167 -0
- package/dist-storybook/assets/omit-CRXr8Lio.js +1 -0
- package/dist-storybook/assets/option-item-DFWc14Up.js +1 -0
- package/dist-storybook/assets/{option-item.stories-BvXoc8WX.js → option-item.stories-DqA-ydWX.js} +3 -3
- package/dist-storybook/assets/pagination-CjgiVNvu.js +1 -0
- package/dist-storybook/assets/{pagination.stories-_5qj2nTS.js → pagination.stories-BsKHvdF4.js} +4 -4
- package/dist-storybook/assets/{radio.stories-BNR-wwuw.js → radio.stories-CBmxZRxo.js} +10 -10
- package/dist-storybook/assets/{rating.stories-CI0LG0Qq.js → rating.stories-CcdFtcNH.js} +9 -9
- package/dist-storybook/assets/react-18-D2tl8ksm.js +1 -0
- package/dist-storybook/assets/{react-I9jCW2VV.js → react-DO0-owxu.js} +1 -1
- package/dist-storybook/assets/search-field-zl4ROLfn.js +1 -0
- package/dist-storybook/assets/{search-field.stories-CKXC6-Za.js → search-field.stories-DoclnxtC.js} +1 -1
- package/dist-storybook/assets/{section.stories-9vd48AgB.js → section.stories-Bqz_QgYp.js} +8 -8
- package/dist-storybook/assets/sheet-body-2dWL2AE5.js +1 -0
- package/dist-storybook/assets/sheet-footer-DuPhbVOb.js +1 -0
- package/dist-storybook/assets/{sheet.stories-C3gLIQsn.js → sheet.stories-CoXnt4LG.js} +4 -4
- package/dist-storybook/assets/skeleton-BVLpHxKT.js +1 -0
- package/dist-storybook/assets/{skeleton.stories-C0y1o1Y_.js → skeleton.stories-B-OfMZId.js} +3 -3
- package/dist-storybook/assets/{store-Ce3Ikv5g.js → store-BwIebEt6.js} +5 -5
- package/dist-storybook/assets/{switch.stories-BdWFln-M.js → switch.stories-D4PQjgbo.js} +9 -9
- package/dist-storybook/assets/syntaxhighlighter-ED5Y7EFY-BxRQp_WE.js +6 -0
- package/dist-storybook/assets/tab-bar.stories-BrcQMypS.js +164 -0
- package/dist-storybook/assets/{text-area.stories-DCt3RB3A.js → text-area.stories-Bpaw2_4A.js} +10 -10
- package/dist-storybook/assets/text-field-CqJG0bIl.js +1 -0
- package/dist-storybook/assets/{text-field.stories-Bqv7f948.js → text-field.stories-PQoP3DbL.js} +1 -1
- package/dist-storybook/assets/toast.stories-DmPy9T3m.js +209 -0
- package/dist-storybook/assets/{tooltip.stories-DDdsuU3U.js → tooltip.stories-Be_kIaDc.js} +8 -8
- package/dist-storybook/assets/typography-CMIMyivt.js +1 -0
- package/dist-storybook/assets/{typography.stories-BzCxaZQU.js → typography.stories-DSt5W_AG.js} +3 -3
- package/dist-storybook/assets/uploader.stories-C5CmeXEk.js +65 -0
- package/dist-storybook/assets/{use-app-pause-ClsUnndr.js → use-app-pause-_ycnhKwZ.js} +3 -3
- package/dist-storybook/assets/{use-app-resume-D_EcIvMd.js → use-app-resume-CWb2s-wo.js} +1 -1
- package/dist-storybook/assets/{use-bottom-tab-bar-BC1cz2uE.js → use-bottom-tab-bar--DRl-8c4.js} +1 -1
- package/dist-storybook/assets/{use-custom-icon-event-cUk4Md0Y.js → use-custom-icon-event-BXcRPkLg.js} +1 -1
- package/dist-storybook/assets/{use-did-hide-BmABiaUE.js → use-did-hide-LBcrwoUo.js} +1 -1
- package/dist-storybook/assets/{use-did-show-CQuySkkT.js → use-did-show-BXLstTgt.js} +1 -1
- package/dist-storybook/assets/{use-histories-CBm09Lno.js → use-histories-Cz7ncXaj.js} +1 -1
- package/dist-storybook/assets/{use-history-7yguNz6O.js → use-history-B_w6SPwr.js} +1 -1
- package/dist-storybook/assets/{use-language-DPyWMce2.js → use-language-D84C9QNT.js} +1 -1
- package/dist-storybook/assets/{use-load-more-KlDJZhj2.js → use-load-more-Bb9YFkAE.js} +1 -1
- package/dist-storybook/assets/{use-location-C7kE1yla.js → use-location-DnxJ5FvJ.js} +1 -1
- package/dist-storybook/assets/{use-navigate-BpIyvtwc.js → use-navigate-OLqoL3vR.js} +3 -3
- package/dist-storybook/assets/{use-navigation-bar-guzwhM_u.js → use-navigation-bar-D5BX6S-r.js} +15 -15
- package/dist-storybook/assets/{use-navigation-type-DOndDqQH.js → use-navigation-type-Cq7T35ur.js} +1 -1
- package/dist-storybook/assets/{use-page-layout-dO6ylI1b.js → use-page-layout-BrFRWwC6.js} +1 -1
- package/dist-storybook/assets/{use-page-scroll-CCG2d2Gb.js → use-page-scroll-BZ8XiPza.js} +1 -1
- package/dist-storybook/assets/{use-pull-to-refresh-lhumDu1H.js → use-pull-to-refresh-BEjtxiFn.js} +1 -1
- package/dist-storybook/assets/{use-settings-changed-Bt58DJ-c.js → use-settings-changed-UaQRSWAg.js} +1 -1
- package/dist-storybook/assets/{use-translate-Jhz6jTXo.js → use-translate-BO8E9Sde.js} +1 -1
- package/dist-storybook/iframe.html +58 -40
- package/dist-storybook/index.html +8 -16
- package/dist-storybook/index.json +1 -1
- package/dist-storybook/project.json +1 -1
- package/dist-storybook/sb-addons/a11y-2/manager-bundle.js +55 -3
- package/dist-storybook/sb-addons/docs-1/manager-bundle.js +1 -149
- package/dist-storybook/sb-addons/storybook-build-3/manager-bundle.js +19 -1
- package/dist-storybook/sb-addons/storybook-core-server-presets-0/common-manager-bundle.js +93 -436
- package/dist-storybook/sb-manager/globals-runtime.js +73307 -65142
- package/dist-storybook/sb-manager/globals.js +6 -16
- package/dist-storybook/sb-manager/manager-stores.js +23 -0
- package/dist-storybook/sb-manager/runtime.js +17679 -10455
- package/dist-storybook/stories-data.json +91 -27
- package/dist-storybook/vite-inject-mocker-entry.js +2 -2
- package/package.json +5 -5
- package/dist-storybook/assets/Color-AVL7NMMY-XA8cFKdV.js +0 -1
- package/dist-storybook/assets/DocsRenderer-PQXLIZUC-D10-0Yfb.js +0 -2
- package/dist-storybook/assets/_baseClone-DQVxEhny.js +0 -1
- package/dist-storybook/assets/alert-CKwsuaPI.js +0 -1
- package/dist-storybook/assets/app-CTv8lFU3.js +0 -1
- package/dist-storybook/assets/avatar-rWcYGe6j.js +0 -1
- package/dist-storybook/assets/avatar.stories-8lrbhMma.js +0 -136
- package/dist-storybook/assets/badge-VcjGVEum.js +0 -1
- package/dist-storybook/assets/blocks-DKR3P4qW.js +0 -1243
- package/dist-storybook/assets/bottom-tab-bar-B6IAoRwz.js +0 -115
- package/dist-storybook/assets/bottom-tab-bar.stories-DXzLlO5o.js +0 -186
- package/dist-storybook/assets/button-DJH3RlJl.js +0 -1
- package/dist-storybook/assets/calendar-C4Xe_TW2.js +0 -1
- package/dist-storybook/assets/carousel-DJlgMyS5.js +0 -37
- package/dist-storybook/assets/carousel.stories-3rA3nxdL.js +0 -217
- package/dist-storybook/assets/checkbox-JOxcmyCZ.js +0 -1
- package/dist-storybook/assets/checkbox.stories-ge3pgfBb.js +0 -201
- package/dist-storybook/assets/chip-Crt60rph.js +0 -1
- package/dist-storybook/assets/date-field-range-B-sv9nbW.js +0 -1
- package/dist-storybook/assets/date-field.stories-B9G2heHt.js +0 -129
- package/dist-storybook/assets/date-picker-BPzKPdhO.js +0 -1
- package/dist-storybook/assets/dialog-BAfGQzk5.js +0 -1
- package/dist-storybook/assets/dialog.stories-vDMKz9Tw.js +0 -212
- package/dist-storybook/assets/dropdown-Dtomaqpw.js +0 -247
- package/dist-storybook/assets/dropdown.stories-Cj0HM0VI.js +0 -200
- package/dist-storybook/assets/icon-CdiFzFyf.js +0 -1
- package/dist-storybook/assets/iframe-BHaCv4dM.css +0 -1
- package/dist-storybook/assets/iframe-DfPay7Zl.js +0 -1071
- package/dist-storybook/assets/image-CMKb-R3x.js +0 -9
- package/dist-storybook/assets/index-BWpuenI4.js +0 -1
- package/dist-storybook/assets/index-DqZh6B0b.js +0 -1
- package/dist-storybook/assets/input-wrapper-CgaUwbbE.js +0 -1
- package/dist-storybook/assets/label-D44azUgi.js +0 -27
- package/dist-storybook/assets/matchers-7Z3WT2CE-Dw4MQV_s.js +0 -14
- package/dist-storybook/assets/navigation-bar-DK3TxcTu.js +0 -79
- package/dist-storybook/assets/navigation-bar.stories-CB3Kg-sH.js +0 -73
- package/dist-storybook/assets/number-field-Bz7su9S1.js +0 -1
- package/dist-storybook/assets/number-field.stories-DSxPSzLv.js +0 -167
- package/dist-storybook/assets/omit-BWHsnDSR.js +0 -1
- package/dist-storybook/assets/option-item-CpeNcb5w.js +0 -1
- package/dist-storybook/assets/pagination-Cp-DHO4Q.js +0 -1
- package/dist-storybook/assets/proxy-B4G9nIBd.js +0 -1
- package/dist-storybook/assets/radio-D0aV0RIg.js +0 -1
- package/dist-storybook/assets/rating-D2e8RTGl.js +0 -1
- package/dist-storybook/assets/react-18-C7pDmBBf.js +0 -9
- package/dist-storybook/assets/search-field-DINESW8Y.js +0 -1
- package/dist-storybook/assets/section-content-D49PabBW.js +0 -1
- package/dist-storybook/assets/sheet-footer-nEdxsYan.js +0 -1
- package/dist-storybook/assets/skeleton-B12XbNAJ.js +0 -1
- package/dist-storybook/assets/switch-D0Z9tWin.js +0 -1
- package/dist-storybook/assets/tab-bar-kExoGg5P.js +0 -31
- package/dist-storybook/assets/tab-bar.stories-BgDXX0of.js +0 -136
- package/dist-storybook/assets/text-area-GKy5HL12.js +0 -1
- package/dist-storybook/assets/text-field-CGWNqitB.js +0 -1
- package/dist-storybook/assets/toast-provider-DKSrfhJD.js +0 -9
- package/dist-storybook/assets/toast.stories-CcFzS6QI.js +0 -201
- package/dist-storybook/assets/tooltip-B9rDI6z9.js +0 -1
- package/dist-storybook/assets/typography-CB8hPDyK.js +0 -1
- package/dist-storybook/assets/uploader.stories-izVumFqZ.js +0 -65
- package/dist-storybook/assets/visibility-sensor-Jf-Nmil6.js +0 -1
- package/dist-storybook/sb-manager/globals-module-info.js +0 -799
|
@@ -0,0 +1,214 @@
|
|
|
1
|
+
import { jsxs as Q, jsx as h } from "react/jsx-runtime";
|
|
2
|
+
import { useMemo as s, useCallback as x } from "react";
|
|
3
|
+
import { useControllableValue as S } from "ahooks";
|
|
4
|
+
import T from "classnames";
|
|
5
|
+
import { DatePickerItem as D } from "./date-picker-item.js";
|
|
6
|
+
import { prefixClassName as U } from "./date-picker.constant.js";
|
|
7
|
+
import { getRanges as y, getActiveIndex as f } from "./date-picker.utils.js";
|
|
8
|
+
const te = ({
|
|
9
|
+
className: M,
|
|
10
|
+
hour: C,
|
|
11
|
+
day: c,
|
|
12
|
+
month: b,
|
|
13
|
+
year: O,
|
|
14
|
+
minutesProps: L,
|
|
15
|
+
hoursProps: u,
|
|
16
|
+
daysProps: w,
|
|
17
|
+
monthsProps: I,
|
|
18
|
+
yearsProps: k,
|
|
19
|
+
dayOfWeeksProps: A,
|
|
20
|
+
...v
|
|
21
|
+
}) => {
|
|
22
|
+
const [n, a] = S(v, {
|
|
23
|
+
trigger: "onChange",
|
|
24
|
+
valuePropName: "value",
|
|
25
|
+
defaultValue: {
|
|
26
|
+
years: (/* @__PURE__ */ new Date()).getFullYear(),
|
|
27
|
+
minutes: (/* @__PURE__ */ new Date()).getMinutes(),
|
|
28
|
+
hours: (/* @__PURE__ */ new Date()).getHours(),
|
|
29
|
+
days: (/* @__PURE__ */ new Date()).getDate(),
|
|
30
|
+
months: (/* @__PURE__ */ new Date()).getMonth(),
|
|
31
|
+
dayOfWeeks: (/* @__PURE__ */ new Date()).getDay()
|
|
32
|
+
}
|
|
33
|
+
});
|
|
34
|
+
let R = !1;
|
|
35
|
+
c = c || C && (b || O), b = b || (C || c) && O, c && !C && !b && !O && (R = !0, c = !1);
|
|
36
|
+
const N = C, o = s(
|
|
37
|
+
() => y(0, 59, L?.step || 1),
|
|
38
|
+
[L?.step]
|
|
39
|
+
), Y = s(
|
|
40
|
+
() => f(o, n.minutes),
|
|
41
|
+
[o, n.minutes]
|
|
42
|
+
), j = x(
|
|
43
|
+
(t) => {
|
|
44
|
+
a((e) => ({
|
|
45
|
+
...e,
|
|
46
|
+
minutes: o[t % o.length]
|
|
47
|
+
}));
|
|
48
|
+
},
|
|
49
|
+
[o, a]
|
|
50
|
+
), r = s(
|
|
51
|
+
() => y(0, 23, u?.step || 1),
|
|
52
|
+
[u?.step]
|
|
53
|
+
), F = s(
|
|
54
|
+
() => f(r, n.hours),
|
|
55
|
+
[r, n.hours]
|
|
56
|
+
), H = x(
|
|
57
|
+
(t) => {
|
|
58
|
+
a((e) => ({
|
|
59
|
+
...e,
|
|
60
|
+
hours: r[t % r.length]
|
|
61
|
+
}));
|
|
62
|
+
},
|
|
63
|
+
[r, a]
|
|
64
|
+
), m = s(() => {
|
|
65
|
+
const t = new Date(n.years, n.months + 1, 0).getDate();
|
|
66
|
+
return y(1, t, w?.step || 1);
|
|
67
|
+
}, [w?.step, n.months, n.years]), V = s(
|
|
68
|
+
() => f(m, n.days),
|
|
69
|
+
[m, n.days]
|
|
70
|
+
), B = x(
|
|
71
|
+
(t) => {
|
|
72
|
+
a((e) => ({
|
|
73
|
+
...e,
|
|
74
|
+
days: m[t % m.length],
|
|
75
|
+
dayOfWeeks: new Date(
|
|
76
|
+
e.years,
|
|
77
|
+
e.months,
|
|
78
|
+
m[t % m.length]
|
|
79
|
+
).getDay()
|
|
80
|
+
}));
|
|
81
|
+
},
|
|
82
|
+
[m, a]
|
|
83
|
+
), g = s(
|
|
84
|
+
() => y(0, 11, I?.step || 1),
|
|
85
|
+
[I?.step]
|
|
86
|
+
), $ = s(
|
|
87
|
+
() => f(g, n.months),
|
|
88
|
+
[g, n.months]
|
|
89
|
+
), q = x(
|
|
90
|
+
(t) => {
|
|
91
|
+
a((e) => ({
|
|
92
|
+
...e,
|
|
93
|
+
months: g[t % g.length],
|
|
94
|
+
dayOfWeeks: new Date(
|
|
95
|
+
e.years,
|
|
96
|
+
g[t % g.length],
|
|
97
|
+
e.days
|
|
98
|
+
).getDay()
|
|
99
|
+
}));
|
|
100
|
+
},
|
|
101
|
+
[g, a]
|
|
102
|
+
), i = s(
|
|
103
|
+
() => y(1900, 2300, k?.step || 1),
|
|
104
|
+
[k?.step]
|
|
105
|
+
), z = s(
|
|
106
|
+
() => f(i, n.years),
|
|
107
|
+
[i, n.years]
|
|
108
|
+
), E = x(
|
|
109
|
+
(t) => {
|
|
110
|
+
a((e) => ({
|
|
111
|
+
...e,
|
|
112
|
+
years: i[t % i.length],
|
|
113
|
+
dayOfWeeks: new Date(
|
|
114
|
+
i[t % i.length],
|
|
115
|
+
e.months,
|
|
116
|
+
e.days
|
|
117
|
+
).getDay()
|
|
118
|
+
}));
|
|
119
|
+
},
|
|
120
|
+
[i, a]
|
|
121
|
+
), l = s(
|
|
122
|
+
() => y(0, 59, A?.step || 1),
|
|
123
|
+
[A?.step]
|
|
124
|
+
), G = s(
|
|
125
|
+
() => f(l, n.dayOfWeeks),
|
|
126
|
+
[l, n.dayOfWeeks]
|
|
127
|
+
), J = x(
|
|
128
|
+
(t) => {
|
|
129
|
+
a((e) => {
|
|
130
|
+
const d = new Date(e.years, e.months, e.days), W = l[t % l.length], K = d.getDay() - W;
|
|
131
|
+
return d.setDate(d.getDate() - K), {
|
|
132
|
+
...e,
|
|
133
|
+
years: d.getFullYear(),
|
|
134
|
+
months: d.getMonth(),
|
|
135
|
+
days: d.getDate(),
|
|
136
|
+
dayOfWeeks: W
|
|
137
|
+
};
|
|
138
|
+
});
|
|
139
|
+
},
|
|
140
|
+
[l, a]
|
|
141
|
+
);
|
|
142
|
+
return /* @__PURE__ */ Q("div", { className: T(`${U}-base`, M), children: [
|
|
143
|
+
c && /* @__PURE__ */ h(
|
|
144
|
+
D,
|
|
145
|
+
{
|
|
146
|
+
items: m,
|
|
147
|
+
activeIndex: V,
|
|
148
|
+
onChange: B,
|
|
149
|
+
renderLabel: w.renderLabel,
|
|
150
|
+
min: w.min,
|
|
151
|
+
max: w.max
|
|
152
|
+
},
|
|
153
|
+
m.length
|
|
154
|
+
),
|
|
155
|
+
b && /* @__PURE__ */ h(
|
|
156
|
+
D,
|
|
157
|
+
{
|
|
158
|
+
items: g,
|
|
159
|
+
activeIndex: $,
|
|
160
|
+
onChange: q,
|
|
161
|
+
renderLabel: I.renderLabel,
|
|
162
|
+
min: I.min,
|
|
163
|
+
max: I.max
|
|
164
|
+
}
|
|
165
|
+
),
|
|
166
|
+
O && /* @__PURE__ */ h(
|
|
167
|
+
D,
|
|
168
|
+
{
|
|
169
|
+
items: i,
|
|
170
|
+
activeIndex: z,
|
|
171
|
+
onChange: E,
|
|
172
|
+
renderLabel: k.renderLabel,
|
|
173
|
+
min: k.min,
|
|
174
|
+
max: k.max
|
|
175
|
+
}
|
|
176
|
+
),
|
|
177
|
+
R && /* @__PURE__ */ h(
|
|
178
|
+
D,
|
|
179
|
+
{
|
|
180
|
+
items: l,
|
|
181
|
+
activeIndex: G,
|
|
182
|
+
onChange: J,
|
|
183
|
+
renderLabel: A.renderLabel,
|
|
184
|
+
min: A.min,
|
|
185
|
+
max: A.max
|
|
186
|
+
}
|
|
187
|
+
),
|
|
188
|
+
C && /* @__PURE__ */ h(
|
|
189
|
+
D,
|
|
190
|
+
{
|
|
191
|
+
items: r,
|
|
192
|
+
activeIndex: F,
|
|
193
|
+
onChange: H,
|
|
194
|
+
renderLabel: u.renderLabel,
|
|
195
|
+
min: u.min,
|
|
196
|
+
max: u.max
|
|
197
|
+
}
|
|
198
|
+
),
|
|
199
|
+
N && /* @__PURE__ */ h(
|
|
200
|
+
D,
|
|
201
|
+
{
|
|
202
|
+
items: o,
|
|
203
|
+
activeIndex: Y,
|
|
204
|
+
onChange: j,
|
|
205
|
+
renderLabel: L.renderLabel,
|
|
206
|
+
min: L.min,
|
|
207
|
+
max: L.max
|
|
208
|
+
}
|
|
209
|
+
)
|
|
210
|
+
] });
|
|
211
|
+
};
|
|
212
|
+
export {
|
|
213
|
+
te as DatePickerBase
|
|
214
|
+
};
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import { jsx as m } from "react/jsx-runtime";
|
|
2
|
+
import { useRef as R, useCallback as T, useEffect as H } from "react";
|
|
3
|
+
import P from "embla-carousel-react";
|
|
4
|
+
import U from "classnames";
|
|
5
|
+
import { prefixClassName as V, itemConfig as b } from "./date-picker.constant.js";
|
|
6
|
+
import { Typography as x } from "../typography/typography.js";
|
|
7
|
+
const _ = `${V}-item`, {
|
|
8
|
+
CIRCLE_DEGREES: L,
|
|
9
|
+
WHEEL_ITEM_COUNT: $,
|
|
10
|
+
WHEEL_ITEMS_IN_VIEW: Z,
|
|
11
|
+
WHEEL_ITEM_SIZE: v
|
|
12
|
+
} = b, l = L / $, k = l * Z, W = Math.round(
|
|
13
|
+
v / 2 / Math.tan(Math.PI / $)
|
|
14
|
+
), C = (s, e) => Math.abs(s - e) < k, G = (s, e, N, S, c) => {
|
|
15
|
+
const n = s.slideNodes()[e], r = s.scrollProgress() * c, i = s.scrollSnapList()[e] * c, o = i + c, f = i - c;
|
|
16
|
+
let E = !1, d = e * -l;
|
|
17
|
+
if (C(r, i) && (E = !0), C(r, f) && (E = !0, d = -L + (S - e) * l), C(r, o) && (E = !0, d = -(c % L) - e * l), E) {
|
|
18
|
+
const g = Math.abs(r - i) < l / 2;
|
|
19
|
+
n.style.opacity = g ? "1" : "0.25", n.style.transform = `translateY(-${e * 100}%) rotateX(${d}deg) translateZ(${W}px)`;
|
|
20
|
+
} else
|
|
21
|
+
n.style.opacity = "0", n.style.transform = "none";
|
|
22
|
+
}, O = (s, e) => {
|
|
23
|
+
s.containerNode().style.transform = `translateZ(${W}px) rotateX(${e}deg)`;
|
|
24
|
+
}, B = (s) => {
|
|
25
|
+
const { className: e, items: N, activeIndex: S = 0, renderLabel: c, onChange: n } = s, r = !0, [i, o] = P({
|
|
26
|
+
loop: r,
|
|
27
|
+
axis: "y",
|
|
28
|
+
dragFree: !0,
|
|
29
|
+
containScroll: !1,
|
|
30
|
+
watchSlides: !1,
|
|
31
|
+
startIndex: S
|
|
32
|
+
}), f = N.length, E = R(null), d = f * l, g = 0, u = T(
|
|
33
|
+
(t) => {
|
|
34
|
+
if (!t) return;
|
|
35
|
+
const { translate: a, slideLooper: p } = t.internalEngine();
|
|
36
|
+
a.clear(), a.toggleActive(!1), p.loopPoints.forEach(({ translate: h }) => {
|
|
37
|
+
h.clear(), h.toggleActive(!1);
|
|
38
|
+
});
|
|
39
|
+
},
|
|
40
|
+
[]
|
|
41
|
+
), I = T(
|
|
42
|
+
(t) => {
|
|
43
|
+
const p = (f * l - g) * t.scrollProgress();
|
|
44
|
+
O(t, p), t.slideNodes().forEach((h, y) => {
|
|
45
|
+
G(t, y, r, f, d);
|
|
46
|
+
});
|
|
47
|
+
},
|
|
48
|
+
[f, g, d, r]
|
|
49
|
+
);
|
|
50
|
+
return H(() => {
|
|
51
|
+
if (!o) return;
|
|
52
|
+
o.on("pointerUp", (a) => {
|
|
53
|
+
const { scrollTo: p, target: h, location: y } = a.internalEngine(), M = h.get() - y.get(), w = Math.abs(M) < v / 2.5 ? 10 : 0.1, D = M * w;
|
|
54
|
+
p.distance(D, !0);
|
|
55
|
+
}), o.on("scroll", I), o.on("reInit", (a) => {
|
|
56
|
+
u(a), I(a);
|
|
57
|
+
}), u(o), I(o);
|
|
58
|
+
const t = () => {
|
|
59
|
+
n && n(o.selectedScrollSnap());
|
|
60
|
+
};
|
|
61
|
+
return o.on("select", t), () => {
|
|
62
|
+
o.off("select", t);
|
|
63
|
+
};
|
|
64
|
+
}, [o, u, I, n]), /* @__PURE__ */ m("div", { className: U(_, e), children: /* @__PURE__ */ m("div", { className: `${_}__scene`, ref: E, children: /* @__PURE__ */ m("div", { className: `${_}__viewport`, ref: i, children: /* @__PURE__ */ m("div", { className: `${_}__container`, children: N.map((t) => /* @__PURE__ */ m("div", { className: `${_}__slide`, children: /* @__PURE__ */ m(x, { size: "base", weight: "600", children: c?.(t) || t }) }, t)) }) }) }) });
|
|
65
|
+
};
|
|
66
|
+
export {
|
|
67
|
+
B as DatePickerItem,
|
|
68
|
+
O as setContainerStyles
|
|
69
|
+
};
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { jsxs as d, jsx as t } from "react/jsx-runtime";
|
|
2
|
+
import { useState as p, useCallback as C, useEffect as S } from "react";
|
|
3
|
+
import { DatePicker as g } from "./date-picker.js";
|
|
4
|
+
import { Sheet as k } from "../sheet/sheet.js";
|
|
5
|
+
import { SheetHeader as D } from "../sheet/sheet-header.js";
|
|
6
|
+
import { SheetBody as u } from "../sheet/sheet-body.js";
|
|
7
|
+
import { SheetFooter as w } from "../sheet/sheet-footer.js";
|
|
8
|
+
import { Button as x } from "../button/button.js";
|
|
9
|
+
const E = ({
|
|
10
|
+
title: c,
|
|
11
|
+
confirmButton: s,
|
|
12
|
+
open: i,
|
|
13
|
+
onCancel: f,
|
|
14
|
+
value: e,
|
|
15
|
+
defaultValue: l,
|
|
16
|
+
onSelect: h,
|
|
17
|
+
...a
|
|
18
|
+
}) => {
|
|
19
|
+
const n = e !== void 0, [o, r] = p(
|
|
20
|
+
e || l || /* @__PURE__ */ new Date()
|
|
21
|
+
), m = C(() => {
|
|
22
|
+
n && o.getTime() !== e?.getTime() && r(e || /* @__PURE__ */ new Date());
|
|
23
|
+
}, [n, o, e]);
|
|
24
|
+
return S(() => {
|
|
25
|
+
e === null && r(/* @__PURE__ */ new Date()), e && r(e);
|
|
26
|
+
}, [e?.getTime()]), /* @__PURE__ */ d(k, { open: i, children: [
|
|
27
|
+
/* @__PURE__ */ t(
|
|
28
|
+
D,
|
|
29
|
+
{
|
|
30
|
+
title: c,
|
|
31
|
+
closeIcon: !0,
|
|
32
|
+
onCloseClick: () => {
|
|
33
|
+
f?.(), m();
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
),
|
|
37
|
+
/* @__PURE__ */ t(u, { children: i && /* @__PURE__ */ t(g, { ...a, value: o, onChange: r }) }),
|
|
38
|
+
/* @__PURE__ */ t(w, { children: /* @__PURE__ */ t(
|
|
39
|
+
x,
|
|
40
|
+
{
|
|
41
|
+
size: "large",
|
|
42
|
+
children: "Xác nhận",
|
|
43
|
+
theme: "neutral",
|
|
44
|
+
...s,
|
|
45
|
+
onClick: () => {
|
|
46
|
+
h?.(o), m();
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
) })
|
|
50
|
+
] });
|
|
51
|
+
};
|
|
52
|
+
export {
|
|
53
|
+
E as DatePickerSheet
|
|
54
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { getPrefixClassName as E } from "../../utils/classname.js";
|
|
2
|
+
const _ = E("date-picker"), t = {
|
|
3
|
+
CIRCLE_DEGREES: 360,
|
|
4
|
+
WHEEL_ITEM_SIZE: 24,
|
|
5
|
+
WHEEL_ITEM_COUNT: 80,
|
|
6
|
+
WHEEL_ITEMS_IN_VIEW: 4
|
|
7
|
+
};
|
|
8
|
+
export {
|
|
9
|
+
t as itemConfig,
|
|
10
|
+
_ as prefixClassName
|
|
11
|
+
};
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import { jsx as C } from "react/jsx-runtime";
|
|
2
|
+
import { useMemo as r, useCallback as D } from "react";
|
|
3
|
+
import { useControllableValue as v } from "ahooks";
|
|
4
|
+
import M from "../../_virtual/omit.js";
|
|
5
|
+
import { DatePickerBase as O } from "./date-picker-base.js";
|
|
6
|
+
import { getTypePickerProps as W } from "./date-picker.utils.js";
|
|
7
|
+
const F = ({
|
|
8
|
+
min: n,
|
|
9
|
+
max: a,
|
|
10
|
+
renderLabels: u,
|
|
11
|
+
year: p = !0,
|
|
12
|
+
month: i = !0,
|
|
13
|
+
day: y = !0,
|
|
14
|
+
hour: s = !1,
|
|
15
|
+
...m
|
|
16
|
+
}) => {
|
|
17
|
+
const [o, c] = v(m, {
|
|
18
|
+
trigger: "onChange",
|
|
19
|
+
valuePropName: "value",
|
|
20
|
+
defaultValue: /* @__PURE__ */ new Date()
|
|
21
|
+
}), g = r(
|
|
22
|
+
() => ({
|
|
23
|
+
years: o.getFullYear(),
|
|
24
|
+
months: o.getMonth(),
|
|
25
|
+
days: o.getDate(),
|
|
26
|
+
dayOfWeeks: o.getDay(),
|
|
27
|
+
hours: o.getHours(),
|
|
28
|
+
minutes: o.getMinutes()
|
|
29
|
+
}),
|
|
30
|
+
[o]
|
|
31
|
+
), e = D(
|
|
32
|
+
(t) => W({
|
|
33
|
+
type: t,
|
|
34
|
+
value: o,
|
|
35
|
+
max: a,
|
|
36
|
+
min: n,
|
|
37
|
+
hasHour: s,
|
|
38
|
+
renderLabels: u
|
|
39
|
+
}),
|
|
40
|
+
[o, a, n, s, u]
|
|
41
|
+
), h = r(() => e("year"), [e]), l = r(() => e("month"), [e]), P = r(() => e("day"), [e]), f = r(() => e("hour"), [e]), d = r(() => e("minute"), [e]), k = r(
|
|
42
|
+
() => e("dayOfWeek"),
|
|
43
|
+
[e]
|
|
44
|
+
);
|
|
45
|
+
return /* @__PURE__ */ C(
|
|
46
|
+
O,
|
|
47
|
+
{
|
|
48
|
+
...M(m, ["value", "onChange"]),
|
|
49
|
+
year: p,
|
|
50
|
+
month: i,
|
|
51
|
+
day: y,
|
|
52
|
+
hour: s,
|
|
53
|
+
yearsProps: h,
|
|
54
|
+
monthsProps: l,
|
|
55
|
+
daysProps: P,
|
|
56
|
+
hoursProps: f,
|
|
57
|
+
minutesProps: d,
|
|
58
|
+
dayOfWeeksProps: k,
|
|
59
|
+
value: g,
|
|
60
|
+
onChange: (t) => {
|
|
61
|
+
c(
|
|
62
|
+
new Date(
|
|
63
|
+
t.years,
|
|
64
|
+
t.months,
|
|
65
|
+
t.days,
|
|
66
|
+
t.hours,
|
|
67
|
+
t.minutes
|
|
68
|
+
)
|
|
69
|
+
);
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
);
|
|
73
|
+
};
|
|
74
|
+
export {
|
|
75
|
+
F as DatePicker
|
|
76
|
+
};
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { dayjs as a } from "../../utils/date.js";
|
|
2
|
+
const b = (t) => {
|
|
3
|
+
const { type: s, value: e, max: n, min: r, hasHour: l, renderLabels: u } = t;
|
|
4
|
+
let d, f, o;
|
|
5
|
+
switch (s) {
|
|
6
|
+
case "day": {
|
|
7
|
+
o = u?.days || i, d = n && a(n).startOf("month").valueOf() === a(e).startOf("month").valueOf() ? n.getDate() : void 0, f = r && a(r).startOf("month").valueOf() === a(e).startOf("month").valueOf() ? r.getDate() : void 0;
|
|
8
|
+
break;
|
|
9
|
+
}
|
|
10
|
+
case "month": {
|
|
11
|
+
o = u?.months || (l ? g : v), d = n && a(n).startOf("year").valueOf() === a(e).startOf("year").valueOf() ? n.getMonth() : void 0, f = r && a(r).startOf("year").valueOf() === a(e).startOf("year").valueOf() ? r.getMonth() : void 0;
|
|
12
|
+
break;
|
|
13
|
+
}
|
|
14
|
+
case "year": {
|
|
15
|
+
o = u?.years || c, d = n ? n.getFullYear() : void 0, f = r ? r.getFullYear() : void 0;
|
|
16
|
+
break;
|
|
17
|
+
}
|
|
18
|
+
case "hour": {
|
|
19
|
+
o = u?.hours || O, d = n && a(n).startOf("day").valueOf() === a(e).startOf("day").valueOf() ? n.getHours() : void 0, f = r && a(r).startOf("day").valueOf() === a(e).startOf("day").valueOf() ? r.getHours() : void 0;
|
|
20
|
+
break;
|
|
21
|
+
}
|
|
22
|
+
case "minute": {
|
|
23
|
+
o = u?.minutes || h, d = n && a(n).startOf("hour").valueOf() === a(e).startOf("hour").valueOf() ? n.getMinutes() : void 0, f = r && a(r).startOf("hour").valueOf() === a(e).startOf("hour").valueOf() ? r.getMinutes() : void 0;
|
|
24
|
+
break;
|
|
25
|
+
}
|
|
26
|
+
case "dayOfWeek": {
|
|
27
|
+
o = u?.dayOfWeeks || y;
|
|
28
|
+
break;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
return {
|
|
32
|
+
renderLabel: o,
|
|
33
|
+
max: d,
|
|
34
|
+
min: f
|
|
35
|
+
};
|
|
36
|
+
}, p = (t, s, e) => Array.from(
|
|
37
|
+
{ length: Math.floor((s - t + 1) / e) },
|
|
38
|
+
(n, r) => t + r * e
|
|
39
|
+
), S = (t, s) => {
|
|
40
|
+
let e = 0;
|
|
41
|
+
for (; e < t.length; e++) {
|
|
42
|
+
if (t[e] === s) return e;
|
|
43
|
+
if (t[e] > s) return Math.max(e, 0);
|
|
44
|
+
}
|
|
45
|
+
return e - 1;
|
|
46
|
+
}, O = (t) => t.toString().padStart(2, "0"), h = (t) => t.toString().padStart(2, "0"), i = (t) => t.toString().padStart(2, "0"), v = (t) => "tháng " + (t + 1).toString().padStart(2, "0"), g = (t) => "thg " + (t + 1).toString().padStart(2, "0"), c = (t) => t.toString().padStart(4, "0"), y = (t) => ["chủ nhật", "thứ 2", "thứ 3", "thứ 4", "thứ 5", "thứ 6", "thứ 7"][t % 7];
|
|
47
|
+
export {
|
|
48
|
+
S as getActiveIndex,
|
|
49
|
+
p as getRanges,
|
|
50
|
+
b as getTypePickerProps,
|
|
51
|
+
y as renderDayOfWeeksLabel,
|
|
52
|
+
i as renderDaysLabel,
|
|
53
|
+
O as renderHoursLabel,
|
|
54
|
+
h as renderMinutesLabel,
|
|
55
|
+
v as renderMonthsLabel,
|
|
56
|
+
g as renderMonthsThumbLabel,
|
|
57
|
+
c as renderYearsLabel
|
|
58
|
+
};
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
import { jsx as r, jsxs as m } from "react/jsx-runtime";
|
|
2
|
+
import { getPrefixClassName as D } from "../../utils/classname.js";
|
|
3
|
+
import { useState as g, useRef as _, useEffect as n, forwardRef as w } from "react";
|
|
4
|
+
import { createPortal as h } from "react-dom";
|
|
5
|
+
import { useDidShow as R, useDidHide as k } from "@v-miniapp/router";
|
|
6
|
+
import { appStore as l } from "../app/app.store.js";
|
|
7
|
+
import c from "classnames";
|
|
8
|
+
import { Button as z } from "../button/button.js";
|
|
9
|
+
import { Image as A } from "../image/image.js";
|
|
10
|
+
import { Typography as p } from "../typography/typography.js";
|
|
11
|
+
const t = D("dialog"), u = w(
|
|
12
|
+
({
|
|
13
|
+
topImageUrl: e,
|
|
14
|
+
top: o,
|
|
15
|
+
title: s,
|
|
16
|
+
description: a,
|
|
17
|
+
children: i,
|
|
18
|
+
closeAction: d,
|
|
19
|
+
footer: f,
|
|
20
|
+
open: b,
|
|
21
|
+
onBackdropClick: y,
|
|
22
|
+
onCloseClick: N,
|
|
23
|
+
overlay: $ = "default",
|
|
24
|
+
className: v,
|
|
25
|
+
...x
|
|
26
|
+
}, C) => /* @__PURE__ */ m(
|
|
27
|
+
"div",
|
|
28
|
+
{
|
|
29
|
+
ref: C,
|
|
30
|
+
className: c(
|
|
31
|
+
t,
|
|
32
|
+
{ [`${t}--open`]: b },
|
|
33
|
+
v
|
|
34
|
+
),
|
|
35
|
+
...x,
|
|
36
|
+
children: [
|
|
37
|
+
/* @__PURE__ */ r(
|
|
38
|
+
"div",
|
|
39
|
+
{
|
|
40
|
+
className: c(`${t}__overlay`, {
|
|
41
|
+
[`${t}__overlay--blur`]: $ === "blur"
|
|
42
|
+
}),
|
|
43
|
+
onClick: y
|
|
44
|
+
}
|
|
45
|
+
),
|
|
46
|
+
!!d && /* @__PURE__ */ r(
|
|
47
|
+
z,
|
|
48
|
+
{
|
|
49
|
+
className: `${t}__close`,
|
|
50
|
+
leadingIcon: { name: "xmark" },
|
|
51
|
+
size: "large",
|
|
52
|
+
theme: "neutral",
|
|
53
|
+
type: "outline",
|
|
54
|
+
shape: "pill",
|
|
55
|
+
onClick: N
|
|
56
|
+
}
|
|
57
|
+
),
|
|
58
|
+
/* @__PURE__ */ m(
|
|
59
|
+
"div",
|
|
60
|
+
{
|
|
61
|
+
className: c(
|
|
62
|
+
`${t}__box`,
|
|
63
|
+
!!d && `${t}__box--close`
|
|
64
|
+
),
|
|
65
|
+
children: [
|
|
66
|
+
e && /* @__PURE__ */ r(A, { src: e, className: `${t}__image` }),
|
|
67
|
+
o,
|
|
68
|
+
(!!s || !!a) && /* @__PURE__ */ m("div", { className: `${t}__title-group`, children: [
|
|
69
|
+
!!s && /* @__PURE__ */ r(p, { size: "large", weight: 600, children: s }),
|
|
70
|
+
!!a && /* @__PURE__ */ r(p, { size: "base", weight: 400, children: a })
|
|
71
|
+
] }),
|
|
72
|
+
!!i && /* @__PURE__ */ r("div", { className: `${t}__body`, children: i }),
|
|
73
|
+
!!f && /* @__PURE__ */ r("div", { className: `${t}__footer`, children: f })
|
|
74
|
+
]
|
|
75
|
+
}
|
|
76
|
+
)
|
|
77
|
+
]
|
|
78
|
+
}
|
|
79
|
+
)
|
|
80
|
+
), O = ({
|
|
81
|
+
open: e,
|
|
82
|
+
...o
|
|
83
|
+
}) => {
|
|
84
|
+
const [s, a] = g(e), i = _(null);
|
|
85
|
+
return R(() => {
|
|
86
|
+
e && a(e);
|
|
87
|
+
}), k(() => {
|
|
88
|
+
a(!1);
|
|
89
|
+
}), n(() => {
|
|
90
|
+
a(e);
|
|
91
|
+
}, [e]), n(() => {
|
|
92
|
+
s && i.current && document.body.appendChild(i.current);
|
|
93
|
+
}, [s]), h(
|
|
94
|
+
/* @__PURE__ */ r(u, { ref: i, open: s, ...o }),
|
|
95
|
+
document.body
|
|
96
|
+
);
|
|
97
|
+
}, S = ({
|
|
98
|
+
open: e,
|
|
99
|
+
...o
|
|
100
|
+
}) => {
|
|
101
|
+
const [s, a] = g(e), i = _(null);
|
|
102
|
+
return n(() => () => {
|
|
103
|
+
a(!1);
|
|
104
|
+
}, []), n(() => {
|
|
105
|
+
a(e);
|
|
106
|
+
}, [e]), n(() => {
|
|
107
|
+
s && i.current && document.body.appendChild(i.current);
|
|
108
|
+
}, [s]), h(
|
|
109
|
+
/* @__PURE__ */ r(u, { ref: i, open: s, ...o }),
|
|
110
|
+
document.body
|
|
111
|
+
);
|
|
112
|
+
}, J = ({ portal: e = !0, ...o }) => e && l.isUsingApp && l.isUsingRouter ? /* @__PURE__ */ r(O, { ...o }) : e && (!l.isUsingApp || !l.isUsingRouter) ? /* @__PURE__ */ r(S, { ...o }) : /* @__PURE__ */ r(u, { ...o });
|
|
113
|
+
export {
|
|
114
|
+
J as Dialog
|
|
115
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { jsx as o, jsxs as r } from "react/jsx-runtime";
|
|
2
|
+
import { getPrefixClassName as a } from "../../utils/classname.js";
|
|
3
|
+
import { InputWrapper as n } from "../input-wrapper/input-wrapper.js";
|
|
4
|
+
import { Skeleton as i } from "../skeleton/skeleton.js";
|
|
5
|
+
const s = a("dropdown"), m = (e) => /* @__PURE__ */ o(
|
|
6
|
+
n,
|
|
7
|
+
{
|
|
8
|
+
trailingIcon: {
|
|
9
|
+
name: "chevron-down",
|
|
10
|
+
color: "alias-object-secondary",
|
|
11
|
+
size: 20
|
|
12
|
+
},
|
|
13
|
+
...e,
|
|
14
|
+
loadingNode: e.loading && /* @__PURE__ */ r("div", { className: `${s}__loading`, children: [
|
|
15
|
+
/* @__PURE__ */ o(i, { width: 128, height: 13, shape: "pill" }),
|
|
16
|
+
/* @__PURE__ */ o(i, { width: 24, height: 24, shape: "pill" })
|
|
17
|
+
] })
|
|
18
|
+
}
|
|
19
|
+
);
|
|
20
|
+
export {
|
|
21
|
+
m as DropdownBase
|
|
22
|
+
};
|