@nutui/nutui-react 2.6.6 → 2.6.8

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/CHANGELOG.md CHANGED
@@ -1,13 +1,36 @@
1
+ # v2.6.8
2
+ `2024-05-31`
3
+
4
+
5
+ * :sparkles: feat(button): 新增 button 原始类型属性 (#2195) @Jiankian
6
+ * :sparkles: feat(card): add card hide price and shop usage (#2292) @wick
7
+ * :bug: fix(cascader): onPathChange is not a function (#2308) @oasis-cloud
8
+ * :bug: fix: safearea for ac (#2293) @xiaoyatong
9
+ * :bug: fix(InputNumber): 扩大点击区域 (#2302) @xiaoyatong
10
+ * :bug: fix(picker): 函数调用之前检查 locale 是否已经定义 (#2259) @Alex-huxiyang
11
+ * 🏡 chore(demo): 更新组件引用方式 (#2304) @oasis-cloud
12
+ * 🏡 chore: fix typos (#2300) @Snoppy
13
+
14
+
15
+ # v2.6.7
16
+ `2024-05-28`
17
+
18
+
19
+ * :sparkles: feat: 签名组件增加当没有签名或已清空的情况下的参数暴露 (#2288) @xiaoyatong
20
+ * :bug: fix: ActionSheet 增加安全区处理 (#2286) @xiaoyatong
21
+ * :bug: fix(actionsheet): 去掉无意义的 padding,popup 已不再暴露 (#2285) @xiaoyatong
22
+
23
+
1
24
  # v2.6.6
2
25
  `2024-05-24`
3
26
 
4
27
 
5
- *🏡 chore(tag): css样式变量修复 (#2279) @Alex.huxiyang
6
- *🏡 chore(deps): update dependency eslint-plugin-markdown to v5 (#2218) @renovate[bot]
7
- * 📖 docs(uploader): update (#2265) @Eiinu
8
- * :bug: fix(input): placeholder 无法设置空字符串 (#2282) @oasis
9
- * :bug: fix(imagepreview): 阻止冒泡,防止点击图片关闭 (#2281) @Alex.huxiyang
10
- * :bug: fix(FormItem): 修复initialValue属性初始化未被正确加入到Formstore中导致的问题 (#2247) @Alex.huxiyang
28
+ * 🏡 chore(tag): css样式变量修复 (#2279) @Alex-huxiyang
29
+ * 🏡 chore(deps): update dependency eslint-plugin-markdown to v5 (#2218) @renovate[bot]
30
+ * 📖 docs(uploader): update (#2265) @eiinu
31
+ * :bug: fix(input): placeholder 无法设置空字符串 (#2282) @oasis-cloud
32
+ * :bug: fix(imagepreview): 阻止冒泡,防止点击图片关闭 (#2281) @Alex-huxiyang
33
+ * :bug: fix(FormItem): 修复initialValue属性初始化未被正确加入到Formstore中导致的问题 (#2247) @Alex-huxiyang
11
34
 
12
35
 
13
36
  # v2.6.5
@@ -1 +1 @@
1
- .nut-overlay{position:fixed;top:0;left:0;width:100%;height:100%;background:var(--nutui-overlay-bg-color, var(--nutui-black-10, rgba(0, 0, 0, .7)));z-index:var(--nutui-overlay-zIndex, 1000)}.nut-overlay .wrapper .content{background-color:var(--nutui-overlay-content-bg-color, var(--nutui-gray-1, #ffffff));color:var(--nutui-overlay-content-color, var(--nutui-gray-7, #1a1a1a))}[dir=rtl] .nut-overlay,.nut-rtl .nut-overlay{left:auto;right:0}.nut-overflow-hidden,.nut-overflow-hidden .taro_page{overflow:hidden!important}@keyframes nut-fade-in{0%{opacity:0}1%{opacity:0}to{opacity:1}}@keyframes nut-fade-out{0%{opacity:1}1%{opacity:1}to{opacity:0}}.nut-overlay-slide-enter-active,.nut-overlay-slide-appear-active{animation-fill-mode:both;animation-name:nut-fade-in;animation-duration:var(--nutui-overlay-animation-duration, .3s)}.nut-overlay-slide-exit-active{animation-fill-mode:both;animation-name:nut-fade-out;animation-duration:var(--nutui-overlay-animation-duration, .3s)}.nut-popup{position:fixed;min-height:26%;max-height:100%;overflow-y:auto;background-color:var(--nutui-overlay-content-bg-color, var(--nutui-gray-1, #ffffff));color:var(--nutui-gray-7, #1a1a1a);-webkit-overflow-scrolling:touch;font-size:var(--nutui-font-size-3, 14px)}.nut-popup-title{display:flex;align-items:center;justify-content:center;border-bottom:var(--nutui-popup-title-border-bottom, 0);padding:var(--nutui-popup-title-padding, 16px);position:relative}.nut-popup-title-left{position:absolute;left:var(--nutui-popup-title-padding, 16px)}.nut-popup-title-title{font-weight:var(--nutui-font-weight-bold, 500);font-size:var(--nutui-popup-title-font-size, var(--nutui-font-size-5, 18px))}.nut-popup-title-description{color:var(--nutui-gray-5, #8c8c8c);font-size:var(--nutui-popup-description-font-size, var(--nutui-font-size-1, 10px));font-weight:var(--nutui-font-weight, 400)}.nut-popup-title-right{position:absolute!important;z-index:1;cursor:pointer;width:var(--nutui-popup-icon-size, var(--nutui-font-size-5, 18px));height:var(--nutui-popup-icon-size, var(--nutui-font-size-5, 18px));display:flex;justify-content:center;align-items:center;top:var(--nutui-popup-title-padding, 16px);right:var(--nutui-popup-title-padding, 16px);color:var(--nutui-gray-5, #8c8c8c)}.nut-popup-title-right:active{opacity:.7}.nut-popup-title-right-top-left{top:var(--nutui-popup-title-padding, 16px);left:var(--nutui-popup-title-padding, 16px)}.nut-popup-title-right-bottom-left{bottom:var(--nutui-popup-title-padding, 16px);left:var(--nutui-popup-title-padding, 16px)}.nut-popup-title-right-bottom-right{right:var(--nutui-popup-title-padding, 16px);bottom:var(--nutui-popup-title-padding, 16px)}.nut-popup-center{top:50%;left:50%;min-height:10%;transform:translate(-50%,-50%)}.nut-popup-center.nut-popup-round{border-radius:var(--nutui-popup-border-radius, 24px)}.nut-popup-bottom,.nut-popup-top{max-height:83%}.nut-popup-bottom{bottom:0;left:0;width:100%}.nut-popup-bottom.nut-popup-round{border-radius:var(--nutui-popup-border-radius, 24px) var(--nutui-popup-border-radius, 24px) 0 0}.nut-popup-right{top:0;right:0}.nut-popup-right.nut-popup-round{border-radius:var(--nutui-popup-border-radius, 24px) 0 0 var(--nutui-popup-border-radius, 24px)}.nut-popup-left{top:0;left:0}.nut-popup-left.nut-popup-round{border-radius:0 var(--nutui-popup-border-radius, 24px) var(--nutui-popup-border-radius, 24px) 0}.nut-popup-top{top:0;left:0;width:100%}.nut-popup-top.nut-popup-round{border-radius:0 0 var(--nutui-popup-border-radius, 24px) var(--nutui-popup-border-radius, 24px)}@keyframes popup-scale-fade-in{0%{opacity:0;transform:scale(.8)}to{opacity:1;transform:scale(1)}}@keyframes popup-scale-fade-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.8)}}.nut-popup-slide-default-enter-active{animation-fill-mode:both;animation-name:popup-scale-fade-in;animation-duration:var(--nutui-popup-animation-duration, .3s)}.nut-popup-slide-default-exit-active{animation-fill-mode:both;animation-name:popup-scale-fade-out;animation-duration:var(--nutui-popup-animation-duration, .3s)}@keyframes popup-fade-in{0%{opacity:0}to{opacity:1}}@keyframes popup-fade-out{0%{opacity:1}to{opacity:0}}.nut-popup-slide-center-enter-active{animation-fill-mode:both;animation-name:popup-fade-in;animation-duration:var(--nutui-popup-animation-duration, .3s)}.nut-popup-slide-center-exit-active{animation-fill-mode:both;animation-name:popup-fade-out;animation-duration:var(--nutui-popup-animation-duration, .3s)}@keyframes popup-slide-top-enter{0%{transform:translate3d(0,-100%,0)}}@keyframes popup-slide-top-exit{to{transform:translate3d(0,-100%,0)}}.nut-popup-slide-top-enter-active,.nut-popup-slide-top-appear-active{transform:translateZ(0);animation-fill-mode:both;animation-name:popup-slide-top-enter;animation-duration:var(--nutui-popup-animation-duration, .3s)}.nut-popup-slide-top-exit-active{animation-fill-mode:both;animation-name:popup-slide-top-exit;animation-duration:var(--nutui-popup-animation-duration, .3s)}@keyframes popup-slide-right-enter{0%{transform:translate3d(100%,0,0)}}@keyframes popup-slide-right-exit{to{transform:translate3d(100%,0,0)}}.nut-popup-slide-right-enter-active,.nut-popup-slide-right-appear-active{transform:translateZ(0);animation-fill-mode:both;animation-name:popup-slide-right-enter;animation-duration:var(--nutui-popup-animation-duration, .3s)}.nut-popup-slide-right-exit{animation-fill-mode:both;animation-name:popup-slide-right-exit;animation-duration:var(--nutui-popup-animation-duration, .3s)}@keyframes popup-slide-bottom-enter{0%{transform:translate3d(0,100%,0)}}@keyframes slide-bottom-exit{to{transform:translate3d(0,100%,0)}}.nut-popup-slide-bottom-enter-active,.nut-popup-slide-bottom-appear-active{transform:translate(0);animation-fill-mode:both;animation-name:popup-slide-bottom-enter;animation-duration:var(--nutui-popup-animation-duration, .3s)}.nut-popup-slide-bottom-exit{animation-fill-mode:both;animation-name:slide-bottom-exit;animation-duration:var(--nutui-popup-animation-duration, .3s)}@keyframes popup-slide-left-enter{0%{transform:translate3d(-100%,0,0)}}@keyframes popup-slide-left-exit{to{transform:translate3d(-100%,0,0)}}.nut-popup-slide-left-enter-active,.nut-popup-slide-left-appear-active{transform:translate(0);animation-fill-mode:both;animation-name:popup-slide-left-enter;animation-duration:var(--nutui-popup-animation-duration, .3s)}.nut-popup-slide-left-exit-active,.nut-popup-slide-left-exit-done{animation-fill-mode:both;animation-name:popup-slide-left-exit;animation-duration:var(--nutui-popup-animation-duration, .3s)}.nut-popup-slide-default-exit-done.nut-popup,.nut-popup-slide-center-exit-done.nut-popup,.nut-popup-slide-left-exit-done.nut-popup,.nut-popup-slide-right-exit-done.nut-popup,.nut-popup-slide-top-exit-done.nut-popup,.nut-popup-slide-bottom-exit-done.nut-popup{display:none}.nut-popup .nut-overflow-hidden{overflow:hidden!important}[dir=rtl] .nut-popup-title-left,.nut-rtl .nut-popup-title-left{left:auto;right:var(--nutui-popup-title-padding, 16px)}[dir=rtl] .nut-popup-title-right,.nut-rtl .nut-popup-title-right{right:auto;left:var(--nutui-popup-title-padding, 16px)}[dir=rtl] .nut-popup-title-right-top-left,.nut-rtl .nut-popup-title-right-top-left,[dir=rtl] .nut-popup-title-right-bottom-left,.nut-rtl .nut-popup-title-right-bottom-left{left:auto;right:var(--nutui-popup-title-padding, 16px)}[dir=rtl] .nut-popup-title-right-bottom-right,.nut-rtl .nut-popup-title-right-bottom-right{right:auto;left:var(--nutui-popup-title-padding, 16px)}[dir=rtl] .nut-popup-title .nut-icon-ArrowLeft,.nut-rtl .nut-popup-title .nut-icon-ArrowLeft{transform:rotate(180deg)}[dir=rtl] .nut-popup-center,.nut-rtl .nut-popup-center{left:auto;right:50%;transform:translate(50%,-50%)}[dir=rtl] .nut-popup-bottom,.nut-rtl .nut-popup-bottom,[dir=rtl] .nut-popup-top,.nut-rtl .nut-popup-top{left:auto;right:0}.nut-actionsheet{display:block;padding-bottom:constant(safe-area-inset-bottom);padding-bottom:env(safe-area-inset-bottom);text-align:center}.nut-actionsheet.nut-popup{min-height:10%;background-color:var(--nutui-actionsheet-background-color, var(--nutui-gray-1, #ffffff));padding:var(--nutui-actionsheet-padding, 0 4px)}.nut-actionsheet .nut-popup-title{border-bottom:1px solid var(--nutui-actionsheet-border-color, var(--nutui-black-3, rgba(0, 0, 0, .06)))}.nut-actionsheet-list{display:block;list-style:none;padding:0;margin:0;border-radius:var(--nutui-actionsheet-border-radius, 0)}.nut-actionsheet-cancel,.nut-actionsheet-item{display:block;padding:10px;text-align:var(--nutui-actionsheet-item-text-align, center);line-height:var(--nutui-actionsheet-item-line-height, 24px);font-size:var(--nutui-font-size-3, 14px);color:var(--nutui-actionsheet-item-color, var(--nutui-gray-7, #1a1a1a));background-color:var(--nutui-gray-1, #ffffff);cursor:pointer}.nut-actionsheet-cancel-description,.nut-actionsheet-item-description{display:block;font-size:var(--nutui-font-size-2, 12px);color:var(--nutui-gray-6, #595959)}.nut-actionsheet-cancel.danger,.nut-actionsheet-item.danger{color:var(--nutui-actionsheet-item-danger, var(--nutui-color-danger, #fa2c19))}.nut-actionsheet-cancel.disabled,.nut-actionsheet-item.disabled{color:var(--nutui-color-text-disabled, #bfbfbf)!important;cursor:not-allowed}.nut-actionsheet-cancel{margin-top:5px;border-top:1px solid var(--nutui-actionsheet-border-color, var(--nutui-black-3, rgba(0, 0, 0, .06)));border-radius:var(--nutui-actionsheet-border-radius, 0)}
1
+ .nut-overlay{position:fixed;top:0;left:0;width:100%;height:100%;background:var(--nutui-overlay-bg-color, var(--nutui-black-10, rgba(0, 0, 0, .7)));z-index:var(--nutui-overlay-zIndex, 1000)}.nut-overlay .wrapper .content{background-color:var(--nutui-overlay-content-bg-color, var(--nutui-gray-1, #ffffff));color:var(--nutui-overlay-content-color, var(--nutui-gray-7, #1a1a1a))}[dir=rtl] .nut-overlay,.nut-rtl .nut-overlay{left:auto;right:0}.nut-overflow-hidden,.nut-overflow-hidden .taro_page{overflow:hidden!important}@keyframes nut-fade-in{0%{opacity:0}1%{opacity:0}to{opacity:1}}@keyframes nut-fade-out{0%{opacity:1}1%{opacity:1}to{opacity:0}}.nut-overlay-slide-enter-active,.nut-overlay-slide-appear-active{animation-fill-mode:both;animation-name:nut-fade-in;animation-duration:var(--nutui-overlay-animation-duration, .3s)}.nut-overlay-slide-exit-active{animation-fill-mode:both;animation-name:nut-fade-out;animation-duration:var(--nutui-overlay-animation-duration, .3s)}.nut-popup{position:fixed;min-height:26%;max-height:100%;overflow-y:auto;background-color:var(--nutui-overlay-content-bg-color, var(--nutui-gray-1, #ffffff));color:var(--nutui-gray-7, #1a1a1a);-webkit-overflow-scrolling:touch;font-size:var(--nutui-font-size-3, 14px)}.nut-popup-title{display:flex;align-items:center;justify-content:center;border-bottom:var(--nutui-popup-title-border-bottom, 0);padding:var(--nutui-popup-title-padding, 16px);position:relative}.nut-popup-title-left{position:absolute;left:var(--nutui-popup-title-padding, 16px)}.nut-popup-title-title{font-weight:var(--nutui-font-weight-bold, 500);font-size:var(--nutui-popup-title-font-size, var(--nutui-font-size-5, 18px))}.nut-popup-title-description{color:var(--nutui-gray-5, #8c8c8c);font-size:var(--nutui-popup-description-font-size, var(--nutui-font-size-1, 10px));font-weight:var(--nutui-font-weight, 400)}.nut-popup-title-right{position:absolute!important;z-index:1;cursor:pointer;width:var(--nutui-popup-icon-size, var(--nutui-font-size-5, 18px));height:var(--nutui-popup-icon-size, var(--nutui-font-size-5, 18px));display:flex;justify-content:center;align-items:center;top:var(--nutui-popup-title-padding, 16px);right:var(--nutui-popup-title-padding, 16px);color:var(--nutui-gray-5, #8c8c8c)}.nut-popup-title-right:active{opacity:.7}.nut-popup-title-right-top-left{top:var(--nutui-popup-title-padding, 16px);left:var(--nutui-popup-title-padding, 16px)}.nut-popup-title-right-bottom-left{bottom:var(--nutui-popup-title-padding, 16px);left:var(--nutui-popup-title-padding, 16px)}.nut-popup-title-right-bottom-right{right:var(--nutui-popup-title-padding, 16px);bottom:var(--nutui-popup-title-padding, 16px)}.nut-popup-center{top:50%;left:50%;min-height:10%;transform:translate(-50%,-50%)}.nut-popup-center.nut-popup-round{border-radius:var(--nutui-popup-border-radius, 24px)}.nut-popup-bottom,.nut-popup-top{max-height:83%}.nut-popup-bottom{bottom:0;left:0;width:100%}.nut-popup-bottom.nut-popup-round{border-radius:var(--nutui-popup-border-radius, 24px) var(--nutui-popup-border-radius, 24px) 0 0}.nut-popup-right{top:0;right:0}.nut-popup-right.nut-popup-round{border-radius:var(--nutui-popup-border-radius, 24px) 0 0 var(--nutui-popup-border-radius, 24px)}.nut-popup-left{top:0;left:0}.nut-popup-left.nut-popup-round{border-radius:0 var(--nutui-popup-border-radius, 24px) var(--nutui-popup-border-radius, 24px) 0}.nut-popup-top{top:0;left:0;width:100%}.nut-popup-top.nut-popup-round{border-radius:0 0 var(--nutui-popup-border-radius, 24px) var(--nutui-popup-border-radius, 24px)}@keyframes popup-scale-fade-in{0%{opacity:0;transform:scale(.8)}to{opacity:1;transform:scale(1)}}@keyframes popup-scale-fade-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.8)}}.nut-popup-slide-default-enter-active{animation-fill-mode:both;animation-name:popup-scale-fade-in;animation-duration:var(--nutui-popup-animation-duration, .3s)}.nut-popup-slide-default-exit-active{animation-fill-mode:both;animation-name:popup-scale-fade-out;animation-duration:var(--nutui-popup-animation-duration, .3s)}@keyframes popup-fade-in{0%{opacity:0}to{opacity:1}}@keyframes popup-fade-out{0%{opacity:1}to{opacity:0}}.nut-popup-slide-center-enter-active{animation-fill-mode:both;animation-name:popup-fade-in;animation-duration:var(--nutui-popup-animation-duration, .3s)}.nut-popup-slide-center-exit-active{animation-fill-mode:both;animation-name:popup-fade-out;animation-duration:var(--nutui-popup-animation-duration, .3s)}@keyframes popup-slide-top-enter{0%{transform:translate3d(0,-100%,0)}}@keyframes popup-slide-top-exit{to{transform:translate3d(0,-100%,0)}}.nut-popup-slide-top-enter-active,.nut-popup-slide-top-appear-active{transform:translateZ(0);animation-fill-mode:both;animation-name:popup-slide-top-enter;animation-duration:var(--nutui-popup-animation-duration, .3s)}.nut-popup-slide-top-exit-active{animation-fill-mode:both;animation-name:popup-slide-top-exit;animation-duration:var(--nutui-popup-animation-duration, .3s)}@keyframes popup-slide-right-enter{0%{transform:translate3d(100%,0,0)}}@keyframes popup-slide-right-exit{to{transform:translate3d(100%,0,0)}}.nut-popup-slide-right-enter-active,.nut-popup-slide-right-appear-active{transform:translateZ(0);animation-fill-mode:both;animation-name:popup-slide-right-enter;animation-duration:var(--nutui-popup-animation-duration, .3s)}.nut-popup-slide-right-exit{animation-fill-mode:both;animation-name:popup-slide-right-exit;animation-duration:var(--nutui-popup-animation-duration, .3s)}@keyframes popup-slide-bottom-enter{0%{transform:translate3d(0,100%,0)}}@keyframes slide-bottom-exit{to{transform:translate3d(0,100%,0)}}.nut-popup-slide-bottom-enter-active,.nut-popup-slide-bottom-appear-active{transform:translate(0);animation-fill-mode:both;animation-name:popup-slide-bottom-enter;animation-duration:var(--nutui-popup-animation-duration, .3s)}.nut-popup-slide-bottom-exit{animation-fill-mode:both;animation-name:slide-bottom-exit;animation-duration:var(--nutui-popup-animation-duration, .3s)}@keyframes popup-slide-left-enter{0%{transform:translate3d(-100%,0,0)}}@keyframes popup-slide-left-exit{to{transform:translate3d(-100%,0,0)}}.nut-popup-slide-left-enter-active,.nut-popup-slide-left-appear-active{transform:translate(0);animation-fill-mode:both;animation-name:popup-slide-left-enter;animation-duration:var(--nutui-popup-animation-duration, .3s)}.nut-popup-slide-left-exit-active,.nut-popup-slide-left-exit-done{animation-fill-mode:both;animation-name:popup-slide-left-exit;animation-duration:var(--nutui-popup-animation-duration, .3s)}.nut-popup-slide-default-exit-done.nut-popup,.nut-popup-slide-center-exit-done.nut-popup,.nut-popup-slide-left-exit-done.nut-popup,.nut-popup-slide-right-exit-done.nut-popup,.nut-popup-slide-top-exit-done.nut-popup,.nut-popup-slide-bottom-exit-done.nut-popup{display:none}.nut-popup .nut-overflow-hidden{overflow:hidden!important}[dir=rtl] .nut-popup-title-left,.nut-rtl .nut-popup-title-left{left:auto;right:var(--nutui-popup-title-padding, 16px)}[dir=rtl] .nut-popup-title-right,.nut-rtl .nut-popup-title-right{right:auto;left:var(--nutui-popup-title-padding, 16px)}[dir=rtl] .nut-popup-title-right-top-left,.nut-rtl .nut-popup-title-right-top-left,[dir=rtl] .nut-popup-title-right-bottom-left,.nut-rtl .nut-popup-title-right-bottom-left{left:auto;right:var(--nutui-popup-title-padding, 16px)}[dir=rtl] .nut-popup-title-right-bottom-right,.nut-rtl .nut-popup-title-right-bottom-right{right:auto;left:var(--nutui-popup-title-padding, 16px)}[dir=rtl] .nut-popup-title .nut-icon-ArrowLeft,.nut-rtl .nut-popup-title .nut-icon-ArrowLeft{transform:rotate(180deg)}[dir=rtl] .nut-popup-center,.nut-rtl .nut-popup-center{left:auto;right:50%;transform:translate(50%,-50%)}[dir=rtl] .nut-popup-bottom,.nut-rtl .nut-popup-bottom,[dir=rtl] .nut-popup-top,.nut-rtl .nut-popup-top{left:auto;right:0}.nut-actionsheet{text-align:center}.nut-actionsheet.nut-popup{min-height:10%;background-color:var(--nutui-actionsheet-background-color, var(--nutui-gray-1, #ffffff))}.nut-actionsheet .nut-popup-title{border-bottom:1px solid var(--nutui-actionsheet-border-color, var(--nutui-black-3, rgba(0, 0, 0, .06)))}.nut-actionsheet-list{display:block;list-style:none;padding:0;margin:0;border-radius:var(--nutui-actionsheet-border-radius, 0)}.nut-actionsheet-cancel,.nut-actionsheet-item{display:block;padding:10px;text-align:var(--nutui-actionsheet-item-text-align, center);line-height:var(--nutui-actionsheet-item-line-height, 24px);font-size:var(--nutui-font-size-3, 14px);color:var(--nutui-actionsheet-item-color, var(--nutui-gray-7, #1a1a1a));background-color:var(--nutui-gray-1, #ffffff);cursor:pointer}.nut-actionsheet-cancel-description,.nut-actionsheet-item-description{display:block;font-size:var(--nutui-font-size-2, 12px);color:var(--nutui-gray-6, #595959)}.nut-actionsheet-cancel.danger,.nut-actionsheet-item.danger{color:var(--nutui-actionsheet-item-danger, var(--nutui-color-danger, #fa2c19))}.nut-actionsheet-cancel.disabled,.nut-actionsheet-item.disabled{color:var(--nutui-color-text-disabled, #bfbfbf)!important;cursor:not-allowed}.nut-actionsheet-cancel{margin-top:5px;border-top:1px solid var(--nutui-actionsheet-border-color, var(--nutui-black-3, rgba(0, 0, 0, .06)));border-radius:var(--nutui-actionsheet-border-radius, 0)}.nut-actionsheet-safe-area{display:block;width:100%;padding-bottom:constant(safe-area-inset-bottom);padding-bottom:env(safe-area-inset-bottom)}
@@ -33,7 +33,8 @@ const ActionSheet = (props) => {
33
33
  );
34
34
  })) : children,
35
35
  cancelText && React__default.createElement("div", { className: `${classPrefix}-cancel`, onClick: () => cancelActionSheet() }, cancelText)
36
- )
36
+ ),
37
+ React__default.createElement("div", { className: `${classPrefix}-safe-area` })
37
38
  );
38
39
  };
39
40
  ActionSheet.displayName = "NutActionSheet";
package/dist/esm/Card.js CHANGED
@@ -24,19 +24,19 @@ const Card = (props) => {
24
24
  React__default.createElement(
25
25
  "div",
26
26
  { className: `${classPrefix}-right-price` },
27
- React__default.createElement(Price__default, { size: "normal", price }),
28
- priceTag || React__default.createElement(Price__default, { size: "normal", className: `${classPrefix}-right-price-origin`, price: vipPrice })
27
+ price && React__default.createElement(Price__default, { size: "normal", price }),
28
+ priceTag || vipPrice && React__default.createElement(Price__default, { size: "normal", className: `${classPrefix}-right-price-origin`, price: vipPrice })
29
29
  ),
30
30
  React__default.createElement("div", { className: `${classPrefix}-right-other` }, tag || React__default.createElement(
31
31
  React__default.Fragment,
32
32
  null,
33
- React__default.createElement(Tag__default, { type: "danger" }, shopDescription),
34
- React__default.createElement(Tag__default, { plain: true }, delivery)
33
+ shopDescription && React__default.createElement(Tag__default, { type: "danger" }, shopDescription),
34
+ delivery && React__default.createElement(Tag__default, { plain: true }, delivery)
35
35
  )),
36
36
  React__default.createElement(
37
37
  "div",
38
38
  { className: `${classPrefix}-right-shop` },
39
- React__default.createElement("div", { className: `${classPrefix}-right-shop-name` }, shopName),
39
+ shopName && React__default.createElement("div", { className: `${classPrefix}-right-shop-name` }, shopName),
40
40
  extra
41
41
  )
42
42
  )
@@ -132,10 +132,10 @@ const InputNumber = (props) => {
132
132
  Object.assign({ className: classes, style }, restProps),
133
133
  React__default.createElement(
134
134
  "div",
135
- { className: "nut-input-minus" },
135
+ { className: "nut-input-minus", onClick: handleReduce },
136
136
  React__default.createElement(Minus, { className: classNames("nut-inputnumber-icon icon-minus", {
137
137
  [`${classPrefix}-icon-disabled`]: shadowValue === min || disabled
138
- }), onClick: handleReduce })
138
+ }) })
139
139
  ),
140
140
  React__default.createElement(
141
141
  React__default.Fragment,
@@ -144,10 +144,10 @@ const InputNumber = (props) => {
144
144
  ),
145
145
  React__default.createElement(
146
146
  "div",
147
- { className: "nut-input-add" },
147
+ { className: "nut-input-add", onClick: handlePlus },
148
148
  React__default.createElement(Plus, { className: classNames("nut-inputnumber-icon icon-plus", {
149
149
  [`${classPrefix}-icon-disabled`]: shadowValue === max || disabled
150
- }), onClick: handlePlus })
150
+ }) })
151
151
  )
152
152
  );
153
153
  };
@@ -385,7 +385,7 @@ const InternalPicker = (props, ref) => {
385
385
  e.stopPropagation();
386
386
  onCancel === null || onCancel === void 0 ? void 0 : onCancel();
387
387
  setInnerVisible(false);
388
- } }, locale.cancel),
388
+ } }, locale === null || locale === void 0 ? void 0 : locale.cancel),
389
389
  React__default.createElement("div", { className: `${classPrefix}-title` }, title || ""),
390
390
  React__default.createElement("span", { className: `${classPrefix}-confirm-btn`, onClick: (e) => {
391
391
  e.stopPropagation();
@@ -18,6 +18,7 @@ const InternalSignature = (props, ref) => {
18
18
  return !!(elem.getContext && elem.getContext("2d"));
19
19
  };
20
20
  const [isCanvasSupported, setIsCanvasSupported] = useState(false);
21
+ const isSignedRef = useRef(false);
21
22
  const isSupportTouch = canUseDom ? "ontouchstart" in window : false;
22
23
  const events = isSupportTouch ? ["touchstart", "touchmove", "touchend", "touchleave"] : ["mousedown", "mousemove", "mouseup", "mouseleave"];
23
24
  useEffect(() => {
@@ -33,6 +34,7 @@ const InternalSignature = (props, ref) => {
33
34
  }, [isCanvasSupported]);
34
35
  const startEventHandler = (event) => {
35
36
  event.preventDefault();
37
+ isSignedRef.current = true;
36
38
  if (ctx.current && canvasRef.current) {
37
39
  ctx.current.beginPath();
38
40
  ctx.current.lineWidth = lineWidth;
@@ -73,6 +75,7 @@ const InternalSignature = (props, ref) => {
73
75
  }
74
76
  };
75
77
  const handleClearBtn = () => {
78
+ isSignedRef.current = false;
76
79
  if (canvasRef.current && ctx.current) {
77
80
  canvasRef.current.addEventListener(events[2], endEventHandler, false);
78
81
  ctx.current.clearRect(0, 0, canvasWidth, canvasHeight);
@@ -81,7 +84,11 @@ const InternalSignature = (props, ref) => {
81
84
  onClear && onClear();
82
85
  };
83
86
  const onSave = (canvas) => {
84
- let dataurl;
87
+ let dataurl = "";
88
+ if (!isSignedRef.current) {
89
+ onConfirm && onConfirm(canvas, dataurl, isSignedRef.current);
90
+ return;
91
+ }
85
92
  switch (type) {
86
93
  case "png":
87
94
  dataurl = canvas.toDataURL("image/png");
@@ -92,7 +99,7 @@ const InternalSignature = (props, ref) => {
92
99
  default:
93
100
  dataurl = canvas.toDataURL("image/png");
94
101
  }
95
- onConfirm && onConfirm(canvas, dataurl);
102
+ onConfirm && onConfirm(canvas, dataurl, isSignedRef.current);
96
103
  };
97
104
  useImperativeHandle(ref, () => ({
98
105
  confirm: () => {
@@ -293,7 +293,7 @@ const InternalCascader = (props, ref) => {
293
293
  const pathNodes = state.panes.map((item) => item.selectedNode);
294
294
  const optionParams = pathNodes.map((item) => item.value);
295
295
  onChange(optionParams, pathNodes);
296
- onPathChange(optionParams, pathNodes);
296
+ onPathChange === null || onPathChange === void 0 ? void 0 : onPathChange(optionParams, pathNodes);
297
297
  setInnerValue(optionParams);
298
298
  }
299
299
  setOptionsData(state.panes);
@@ -315,7 +315,7 @@ const InternalCascader = (props, ref) => {
315
315
  if (!type) {
316
316
  const pathNodes = state.panes.map((item) => item.selectedNode);
317
317
  const optionParams = pathNodes.map((item) => item === null || item === void 0 ? void 0 : item.value);
318
- onPathChange(optionParams, pathNodes);
318
+ onPathChange === null || onPathChange === void 0 ? void 0 : onPathChange(optionParams, pathNodes);
319
319
  }
320
320
  return;
321
321
  }
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui-react v2.6.6 Fri May 24 2024 15:04:38 GMT+0800 (China Standard Time)
2
+ * @nutui/nutui-react v2.6.8 Fri May 31 2024 16:01:04 GMT+0800 (China Standard Time)
3
3
  * (c) 2023 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui-react v2.6.6 Fri May 24 2024 15:04:38 GMT+0800 (China Standard Time)
2
+ * @nutui/nutui-react v2.6.8 Fri May 31 2024 16:01:04 GMT+0800 (China Standard Time)
3
3
  * (c) 2023 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui-react v2.6.6 Fri May 24 2024 15:04:38 GMT+0800 (China Standard Time)
2
+ * @nutui/nutui-react v2.6.8 Fri May 31 2024 16:01:04 GMT+0800 (China Standard Time)
3
3
  * (c) 2023 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui-react v2.6.6 Fri May 24 2024 15:04:38 GMT+0800 (China Standard Time)
2
+ * @nutui/nutui-react v2.6.8 Fri May 31 2024 16:01:04 GMT+0800 (China Standard Time)
3
3
  * (c) 2023 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui-react v2.6.6 Fri May 24 2024 15:04:38 GMT+0800 (China Standard Time)
2
+ * @nutui/nutui-react v2.6.8 Fri May 31 2024 16:01:04 GMT+0800 (China Standard Time)
3
3
  * (c) 2023 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui-react v2.6.6 Fri May 24 2024 15:04:38 GMT+0800 (China Standard Time)
2
+ * @nutui/nutui-react v2.6.8 Fri May 31 2024 16:01:04 GMT+0800 (China Standard Time)
3
3
  * (c) 2023 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui-react v2.6.6 Fri May 24 2024 15:04:38 GMT+0800 (China Standard Time)
2
+ * @nutui/nutui-react v2.6.8 Fri May 31 2024 16:01:04 GMT+0800 (China Standard Time)
3
3
  * (c) 2023 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui-react v2.6.6 Fri May 24 2024 15:03:59 GMT+0800 (China Standard Time)
2
+ * @nutui/nutui-react v2.6.8 Fri May 31 2024 16:00:31 GMT+0800 (China Standard Time)
3
3
  * (c) 2023 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -11902,7 +11902,7 @@ const InternalCascader = (props, ref) => {
11902
11902
  const pathNodes = state.panes.map((item) => item.selectedNode);
11903
11903
  const optionParams = pathNodes.map((item) => item.value);
11904
11904
  onChange(optionParams, pathNodes);
11905
- onPathChange(optionParams, pathNodes);
11905
+ onPathChange == null ? void 0 : onPathChange(optionParams, pathNodes);
11906
11906
  setInnerValue(optionParams);
11907
11907
  }
11908
11908
  setOptionsData(state.panes);
@@ -11924,7 +11924,7 @@ const InternalCascader = (props, ref) => {
11924
11924
  if (!type4) {
11925
11925
  const pathNodes = state.panes.map((item) => item.selectedNode);
11926
11926
  const optionParams = pathNodes.map((item) => item == null ? void 0 : item.value);
11927
- onPathChange(optionParams, pathNodes);
11927
+ onPathChange == null ? void 0 : onPathChange(optionParams, pathNodes);
11928
11928
  }
11929
11929
  return;
11930
11930
  }
@@ -14428,7 +14428,7 @@ const InternalPicker = (props, ref) => {
14428
14428
  setInnerVisible(false);
14429
14429
  }
14430
14430
  },
14431
- locale.cancel
14431
+ locale == null ? void 0 : locale.cancel
14432
14432
  ), /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-title` }, title || ""), /* @__PURE__ */ React__default.createElement(
14433
14433
  "span",
14434
14434
  {
@@ -16675,13 +16675,12 @@ const InputNumber = (props) => {
16675
16675
  onChange == null ? void 0 : onChange(parseFloat(valueStr || "0").toFixed(digits), e2);
16676
16676
  }
16677
16677
  };
16678
- return /* @__PURE__ */ React__default.createElement("div", { className: classes, style, ...restProps }, /* @__PURE__ */ React__default.createElement("div", { className: "nut-input-minus" }, /* @__PURE__ */ React__default.createElement(
16678
+ return /* @__PURE__ */ React__default.createElement("div", { className: classes, style, ...restProps }, /* @__PURE__ */ React__default.createElement("div", { className: "nut-input-minus", onClick: handleReduce }, /* @__PURE__ */ React__default.createElement(
16679
16679
  e$6,
16680
16680
  {
16681
16681
  className: classNames("nut-inputnumber-icon icon-minus", {
16682
16682
  [`${classPrefix$g}-icon-disabled`]: shadowValue === min || disabled
16683
- }),
16684
- onClick: handleReduce
16683
+ })
16685
16684
  }
16686
16685
  )), /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, /* @__PURE__ */ React__default.createElement(
16687
16686
  "input",
@@ -16695,13 +16694,12 @@ const InputNumber = (props) => {
16695
16694
  onBlur: handleBlur,
16696
16695
  onFocus: handleFocus
16697
16696
  }
16698
- )), /* @__PURE__ */ React__default.createElement("div", { className: "nut-input-add" }, /* @__PURE__ */ React__default.createElement(
16697
+ )), /* @__PURE__ */ React__default.createElement("div", { className: "nut-input-add", onClick: handlePlus }, /* @__PURE__ */ React__default.createElement(
16699
16698
  e$2,
16700
16699
  {
16701
16700
  className: classNames("nut-inputnumber-icon icon-plus", {
16702
16701
  [`${classPrefix$g}-icon-disabled`]: shadowValue === max || disabled
16703
- }),
16704
- onClick: handlePlus
16702
+ })
16705
16703
  }
16706
16704
  )));
16707
16705
  };
@@ -18284,6 +18282,7 @@ const InternalSignature = (props, ref) => {
18284
18282
  return !!(elem.getContext && elem.getContext("2d"));
18285
18283
  };
18286
18284
  const [isCanvasSupported, setIsCanvasSupported] = useState(false);
18285
+ const isSignedRef = useRef(false);
18287
18286
  const isSupportTouch = canUseDom ? "ontouchstart" in window : false;
18288
18287
  const events = isSupportTouch ? ["touchstart", "touchmove", "touchend", "touchleave"] : ["mousedown", "mousemove", "mouseup", "mouseleave"];
18289
18288
  useEffect(() => {
@@ -18299,6 +18298,7 @@ const InternalSignature = (props, ref) => {
18299
18298
  }, [isCanvasSupported]);
18300
18299
  const startEventHandler = (event) => {
18301
18300
  event.preventDefault();
18301
+ isSignedRef.current = true;
18302
18302
  if (ctx2.current && canvasRef.current) {
18303
18303
  ctx2.current.beginPath();
18304
18304
  ctx2.current.lineWidth = lineWidth;
@@ -18339,6 +18339,7 @@ const InternalSignature = (props, ref) => {
18339
18339
  }
18340
18340
  };
18341
18341
  const handleClearBtn = () => {
18342
+ isSignedRef.current = false;
18342
18343
  if (canvasRef.current && ctx2.current) {
18343
18344
  canvasRef.current.addEventListener(events[2], endEventHandler, false);
18344
18345
  ctx2.current.clearRect(0, 0, canvasWidth, canvasHeight);
@@ -18347,7 +18348,11 @@ const InternalSignature = (props, ref) => {
18347
18348
  onClear && onClear();
18348
18349
  };
18349
18350
  const onSave = (canvas) => {
18350
- let dataurl;
18351
+ let dataurl = "";
18352
+ if (!isSignedRef.current) {
18353
+ onConfirm && onConfirm(canvas, dataurl, isSignedRef.current);
18354
+ return;
18355
+ }
18351
18356
  switch (type4) {
18352
18357
  case "png":
18353
18358
  dataurl = canvas.toDataURL("image/png");
@@ -18358,7 +18363,7 @@ const InternalSignature = (props, ref) => {
18358
18363
  default:
18359
18364
  dataurl = canvas.toDataURL("image/png");
18360
18365
  }
18361
- onConfirm && onConfirm(canvas, dataurl);
18366
+ onConfirm && onConfirm(canvas, dataurl, isSignedRef.current);
18362
18367
  };
18363
18368
  useImperativeHandle(ref, () => ({
18364
18369
  confirm: () => {
@@ -19229,7 +19234,8 @@ const ActionSheet = (props) => {
19229
19234
  onClick: () => cancelActionSheet()
19230
19235
  },
19231
19236
  cancelText
19232
- ))
19237
+ )),
19238
+ /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-safe-area` })
19233
19239
  );
19234
19240
  };
19235
19241
  ActionSheet.displayName = "NutActionSheet";
@@ -24635,14 +24641,14 @@ const Card = (props) => {
24635
24641
  ...props
24636
24642
  };
24637
24643
  const classPrefix2 = "nut-card";
24638
- return /* @__PURE__ */ React__default.createElement("div", { className: classNames(classPrefix2, className), style, ...rest }, /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-left` }, /* @__PURE__ */ React__default.createElement("img", { src, alt: "" })), /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-right` }, /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-right-title` }, title), description, /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-right-price` }, /* @__PURE__ */ React__default.createElement(Price, { size: "normal", price }), priceTag || /* @__PURE__ */ React__default.createElement(
24644
+ return /* @__PURE__ */ React__default.createElement("div", { className: classNames(classPrefix2, className), style, ...rest }, /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-left` }, /* @__PURE__ */ React__default.createElement("img", { src, alt: "" })), /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-right` }, /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-right-title` }, title), description, /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-right-price` }, price && /* @__PURE__ */ React__default.createElement(Price, { size: "normal", price }), priceTag || vipPrice && /* @__PURE__ */ React__default.createElement(
24639
24645
  Price,
24640
24646
  {
24641
24647
  size: "normal",
24642
24648
  className: `${classPrefix2}-right-price-origin`,
24643
24649
  price: vipPrice
24644
24650
  }
24645
- )), /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-right-other` }, tag || /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, /* @__PURE__ */ React__default.createElement(Tag, { type: "danger" }, shopDescription), /* @__PURE__ */ React__default.createElement(Tag, { plain: true }, delivery))), /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-right-shop` }, /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-right-shop-name` }, shopName), extra)));
24651
+ )), /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-right-other` }, tag || /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, shopDescription && /* @__PURE__ */ React__default.createElement(Tag, { type: "danger" }, shopDescription), delivery && /* @__PURE__ */ React__default.createElement(Tag, { plain: true }, delivery))), /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-right-shop` }, shopName && /* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-right-shop-name` }, shopName), extra)));
24646
24652
  };
24647
24653
  Card.displayName = "NutCard";
24648
24654
  const defaultProps$4 = {
@@ -2,7 +2,7 @@
2
2
  typeof exports === "object" && typeof module !== "undefined" ? factory(exports, require("react"), require("react-dom")) : typeof define === "function" && define.amd ? define(["exports", "react", "react-dom"], factory) : (global2 = typeof globalThis !== "undefined" ? globalThis : global2 || self, factory((global2.nutui = global2.nutui || {}, global2.nutui.react = {}), global2.React, global2.ReactDOM));
3
3
  })(this, function(exports2, React, ReactDOM) {
4
4
  "use strict";/*!
5
- * @nutui/nutui-react v2.6.6 Fri May 24 2024 15:03:59 GMT+0800 (China Standard Time)
5
+ * @nutui/nutui-react v2.6.8 Fri May 31 2024 16:00:31 GMT+0800 (China Standard Time)
6
6
  * (c) 2023 @jdf2e.
7
7
  * Released under the MIT License.
8
8
  */
@@ -11920,7 +11920,7 @@ Please add \`${key}Action\` when creating your handler.`);
11920
11920
  const pathNodes = state.panes.map((item) => item.selectedNode);
11921
11921
  const optionParams = pathNodes.map((item) => item.value);
11922
11922
  onChange(optionParams, pathNodes);
11923
- onPathChange(optionParams, pathNodes);
11923
+ onPathChange == null ? void 0 : onPathChange(optionParams, pathNodes);
11924
11924
  setInnerValue(optionParams);
11925
11925
  }
11926
11926
  setOptionsData(state.panes);
@@ -11942,7 +11942,7 @@ Please add \`${key}Action\` when creating your handler.`);
11942
11942
  if (!type2) {
11943
11943
  const pathNodes = state.panes.map((item) => item.selectedNode);
11944
11944
  const optionParams = pathNodes.map((item) => item == null ? void 0 : item.value);
11945
- onPathChange(optionParams, pathNodes);
11945
+ onPathChange == null ? void 0 : onPathChange(optionParams, pathNodes);
11946
11946
  }
11947
11947
  return;
11948
11948
  }
@@ -14446,7 +14446,7 @@ Please add \`${key}Action\` when creating your handler.`);
14446
14446
  setInnerVisible(false);
14447
14447
  }
14448
14448
  },
14449
- locale.cancel
14449
+ locale == null ? void 0 : locale.cancel
14450
14450
  ), /* @__PURE__ */ React.createElement("div", { className: `${classPrefix2}-title` }, title || ""), /* @__PURE__ */ React.createElement(
14451
14451
  "span",
14452
14452
  {
@@ -16693,13 +16693,12 @@ Please add \`${key}Action\` when creating your handler.`);
16693
16693
  onChange == null ? void 0 : onChange(parseFloat(valueStr || "0").toFixed(digits), e2);
16694
16694
  }
16695
16695
  };
16696
- return /* @__PURE__ */ React.createElement("div", { className: classes, style, ...restProps }, /* @__PURE__ */ React.createElement("div", { className: "nut-input-minus" }, /* @__PURE__ */ React.createElement(
16696
+ return /* @__PURE__ */ React.createElement("div", { className: classes, style, ...restProps }, /* @__PURE__ */ React.createElement("div", { className: "nut-input-minus", onClick: handleReduce }, /* @__PURE__ */ React.createElement(
16697
16697
  e$6,
16698
16698
  {
16699
16699
  className: classNames("nut-inputnumber-icon icon-minus", {
16700
16700
  [`${classPrefix$g}-icon-disabled`]: shadowValue === min || disabled
16701
- }),
16702
- onClick: handleReduce
16701
+ })
16703
16702
  }
16704
16703
  )), /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(
16705
16704
  "input",
@@ -16713,13 +16712,12 @@ Please add \`${key}Action\` when creating your handler.`);
16713
16712
  onBlur: handleBlur,
16714
16713
  onFocus: handleFocus
16715
16714
  }
16716
- )), /* @__PURE__ */ React.createElement("div", { className: "nut-input-add" }, /* @__PURE__ */ React.createElement(
16715
+ )), /* @__PURE__ */ React.createElement("div", { className: "nut-input-add", onClick: handlePlus }, /* @__PURE__ */ React.createElement(
16717
16716
  e$2,
16718
16717
  {
16719
16718
  className: classNames("nut-inputnumber-icon icon-plus", {
16720
16719
  [`${classPrefix$g}-icon-disabled`]: shadowValue === max || disabled
16721
- }),
16722
- onClick: handlePlus
16720
+ })
16723
16721
  }
16724
16722
  )));
16725
16723
  };
@@ -18302,6 +18300,7 @@ Please add \`${key}Action\` when creating your handler.`);
18302
18300
  return !!(elem.getContext && elem.getContext("2d"));
18303
18301
  };
18304
18302
  const [isCanvasSupported, setIsCanvasSupported] = React.useState(false);
18303
+ const isSignedRef = React.useRef(false);
18305
18304
  const isSupportTouch = canUseDom ? "ontouchstart" in window : false;
18306
18305
  const events = isSupportTouch ? ["touchstart", "touchmove", "touchend", "touchleave"] : ["mousedown", "mousemove", "mouseup", "mouseleave"];
18307
18306
  React.useEffect(() => {
@@ -18317,6 +18316,7 @@ Please add \`${key}Action\` when creating your handler.`);
18317
18316
  }, [isCanvasSupported]);
18318
18317
  const startEventHandler = (event) => {
18319
18318
  event.preventDefault();
18319
+ isSignedRef.current = true;
18320
18320
  if (ctx2.current && canvasRef.current) {
18321
18321
  ctx2.current.beginPath();
18322
18322
  ctx2.current.lineWidth = lineWidth;
@@ -18357,6 +18357,7 @@ Please add \`${key}Action\` when creating your handler.`);
18357
18357
  }
18358
18358
  };
18359
18359
  const handleClearBtn = () => {
18360
+ isSignedRef.current = false;
18360
18361
  if (canvasRef.current && ctx2.current) {
18361
18362
  canvasRef.current.addEventListener(events[2], endEventHandler, false);
18362
18363
  ctx2.current.clearRect(0, 0, canvasWidth, canvasHeight);
@@ -18365,7 +18366,11 @@ Please add \`${key}Action\` when creating your handler.`);
18365
18366
  onClear && onClear();
18366
18367
  };
18367
18368
  const onSave = (canvas) => {
18368
- let dataurl;
18369
+ let dataurl = "";
18370
+ if (!isSignedRef.current) {
18371
+ onConfirm && onConfirm(canvas, dataurl, isSignedRef.current);
18372
+ return;
18373
+ }
18369
18374
  switch (type2) {
18370
18375
  case "png":
18371
18376
  dataurl = canvas.toDataURL("image/png");
@@ -18376,7 +18381,7 @@ Please add \`${key}Action\` when creating your handler.`);
18376
18381
  default:
18377
18382
  dataurl = canvas.toDataURL("image/png");
18378
18383
  }
18379
- onConfirm && onConfirm(canvas, dataurl);
18384
+ onConfirm && onConfirm(canvas, dataurl, isSignedRef.current);
18380
18385
  };
18381
18386
  React.useImperativeHandle(ref, () => ({
18382
18387
  confirm: () => {
@@ -19247,7 +19252,8 @@ Please add \`${key}Action\` when creating your handler.`);
19247
19252
  onClick: () => cancelActionSheet()
19248
19253
  },
19249
19254
  cancelText
19250
- ))
19255
+ )),
19256
+ /* @__PURE__ */ React.createElement("div", { className: `${classPrefix2}-safe-area` })
19251
19257
  );
19252
19258
  };
19253
19259
  ActionSheet.displayName = "NutActionSheet";
@@ -24653,14 +24659,14 @@ Please add \`${key}Action\` when creating your handler.`);
24653
24659
  ...props
24654
24660
  };
24655
24661
  const classPrefix2 = "nut-card";
24656
- return /* @__PURE__ */ React.createElement("div", { className: classNames(classPrefix2, className), style, ...rest }, /* @__PURE__ */ React.createElement("div", { className: `${classPrefix2}-left` }, /* @__PURE__ */ React.createElement("img", { src, alt: "" })), /* @__PURE__ */ React.createElement("div", { className: `${classPrefix2}-right` }, /* @__PURE__ */ React.createElement("div", { className: `${classPrefix2}-right-title` }, title), description, /* @__PURE__ */ React.createElement("div", { className: `${classPrefix2}-right-price` }, /* @__PURE__ */ React.createElement(Price, { size: "normal", price }), priceTag || /* @__PURE__ */ React.createElement(
24662
+ return /* @__PURE__ */ React.createElement("div", { className: classNames(classPrefix2, className), style, ...rest }, /* @__PURE__ */ React.createElement("div", { className: `${classPrefix2}-left` }, /* @__PURE__ */ React.createElement("img", { src, alt: "" })), /* @__PURE__ */ React.createElement("div", { className: `${classPrefix2}-right` }, /* @__PURE__ */ React.createElement("div", { className: `${classPrefix2}-right-title` }, title), description, /* @__PURE__ */ React.createElement("div", { className: `${classPrefix2}-right-price` }, price && /* @__PURE__ */ React.createElement(Price, { size: "normal", price }), priceTag || vipPrice && /* @__PURE__ */ React.createElement(
24657
24663
  Price,
24658
24664
  {
24659
24665
  size: "normal",
24660
24666
  className: `${classPrefix2}-right-price-origin`,
24661
24667
  price: vipPrice
24662
24668
  }
24663
- )), /* @__PURE__ */ React.createElement("div", { className: `${classPrefix2}-right-other` }, tag || /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(Tag, { type: "danger" }, shopDescription), /* @__PURE__ */ React.createElement(Tag, { plain: true }, delivery))), /* @__PURE__ */ React.createElement("div", { className: `${classPrefix2}-right-shop` }, /* @__PURE__ */ React.createElement("div", { className: `${classPrefix2}-right-shop-name` }, shopName), extra)));
24669
+ )), /* @__PURE__ */ React.createElement("div", { className: `${classPrefix2}-right-other` }, tag || /* @__PURE__ */ React.createElement(React.Fragment, null, shopDescription && /* @__PURE__ */ React.createElement(Tag, { type: "danger" }, shopDescription), delivery && /* @__PURE__ */ React.createElement(Tag, { plain: true }, delivery))), /* @__PURE__ */ React.createElement("div", { className: `${classPrefix2}-right-shop` }, shopName && /* @__PURE__ */ React.createElement("div", { className: `${classPrefix2}-right-shop-name` }, shopName), extra)));
24664
24670
  };
24665
24671
  Card.displayName = "NutCard";
24666
24672
  const defaultProps$4 = {
@@ -1,14 +1,10 @@
1
1
 
2
2
  .nut-actionsheet {
3
- display: block;
4
- padding-bottom: constant(safe-area-inset-bottom);
5
- padding-bottom: env(safe-area-inset-bottom);
6
3
  text-align: center;
7
4
 
8
5
  &.nut-popup {
9
6
  min-height: 10%;
10
7
  background-color: $actionsheet-background-color;
11
- padding: $actionsheet-padding;
12
8
  }
13
9
 
14
10
  .nut-popup-title {
@@ -55,4 +51,11 @@
55
51
  border-top: 1px solid $actionsheet-border-color;
56
52
  border-radius: $actionsheet-border-radius;
57
53
  }
54
+
55
+ &-safe-area {
56
+ display: block;
57
+ width: 100%;
58
+ padding-bottom: constant(safe-area-inset-bottom);
59
+ padding-bottom: env(safe-area-inset-bottom);
60
+ }
58
61
  }