@nutui/nutui-react 2.6.6 → 2.6.7
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 +15 -6
- package/dist/esm/ActionSheet/style/style.css +1 -1
- package/dist/esm/ActionSheet.js +2 -1
- package/dist/esm/Signature.js +9 -2
- package/dist/locales/base.js +1 -1
- package/dist/locales/en-US.js +1 -1
- package/dist/locales/id-ID.js +1 -1
- package/dist/locales/tr-TR.js +1 -1
- package/dist/locales/zh-CN.js +1 -1
- package/dist/locales/zh-TW.js +1 -1
- package/dist/locales/zh-UG.js +1 -1
- package/dist/nutui.react.es.js +12 -4
- package/dist/nutui.react.umd.js +12 -4
- package/dist/packages/actionsheet/actionsheet.scss +7 -1
- package/dist/style.css +1 -1
- package/dist/style.mjs +1 -1
- package/dist/styles/variables-jmapp.scss +0 -1
- package/dist/styles/variables.scss +0 -1
- package/dist/types/packages/configprovider/types.d.ts +1 -1
- package/dist/types/packages/signature/signature.d.ts +1 -1
- package/dist/types/packages/signature/signature.taro.d.ts +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,13 +1,22 @@
|
|
|
1
|
+
# v2.6.7
|
|
2
|
+
`2024-05-28`
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
* :sparkles: feat: 签名组件增加当没有签名或已清空的情况下的参数暴露 (#2288) @xiaoyatong
|
|
6
|
+
* :bug: fix: ActionSheet 增加安全区处理 (#2286) @xiaoyatong
|
|
7
|
+
* :bug: fix(actionsheet): 去掉无意义的 padding,popup 已不再暴露 (#2285) @xiaoyatong
|
|
8
|
+
|
|
9
|
+
|
|
1
10
|
# v2.6.6
|
|
2
11
|
`2024-05-24`
|
|
3
12
|
|
|
4
13
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
* 📖 docs(uploader): update (#2265) @
|
|
8
|
-
* :bug: fix(input): placeholder 无法设置空字符串 (#2282) @oasis
|
|
9
|
-
* :bug: fix(imagepreview): 阻止冒泡,防止点击图片关闭 (#2281) @Alex
|
|
10
|
-
* :bug: fix(FormItem): 修复initialValue属性初始化未被正确加入到Formstore中导致的问题 (#2247) @Alex
|
|
14
|
+
* 🏡 chore(tag): css样式变量修复 (#2279) @Alex-huxiyang
|
|
15
|
+
* 🏡 chore(deps): update dependency eslint-plugin-markdown to v5 (#2218) @renovate[bot]
|
|
16
|
+
* 📖 docs(uploader): update (#2265) @eiinu
|
|
17
|
+
* :bug: fix(input): placeholder 无法设置空字符串 (#2282) @oasis-cloud
|
|
18
|
+
* :bug: fix(imagepreview): 阻止冒泡,防止点击图片关闭 (#2281) @Alex-huxiyang
|
|
19
|
+
* :bug: fix(FormItem): 修复initialValue属性初始化未被正确加入到Formstore中导致的问题 (#2247) @Alex-huxiyang
|
|
11
20
|
|
|
12
21
|
|
|
13
22
|
# 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))
|
|
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))}.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)}
|
package/dist/esm/ActionSheet.js
CHANGED
|
@@ -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/Signature.js
CHANGED
|
@@ -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: () => {
|
package/dist/locales/base.js
CHANGED
package/dist/locales/en-US.js
CHANGED
package/dist/locales/id-ID.js
CHANGED
package/dist/locales/tr-TR.js
CHANGED
package/dist/locales/zh-CN.js
CHANGED
package/dist/locales/zh-TW.js
CHANGED
package/dist/locales/zh-UG.js
CHANGED
package/dist/nutui.react.es.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* @nutui/nutui-react v2.6.
|
|
2
|
+
* @nutui/nutui-react v2.6.7 Tue May 28 2024 17:31:53 GMT+0800 (China Standard Time)
|
|
3
3
|
* (c) 2023 @jdf2e.
|
|
4
4
|
* Released under the MIT License.
|
|
5
5
|
*/
|
|
@@ -18284,6 +18284,7 @@ const InternalSignature = (props, ref) => {
|
|
|
18284
18284
|
return !!(elem.getContext && elem.getContext("2d"));
|
|
18285
18285
|
};
|
|
18286
18286
|
const [isCanvasSupported, setIsCanvasSupported] = useState(false);
|
|
18287
|
+
const isSignedRef = useRef(false);
|
|
18287
18288
|
const isSupportTouch = canUseDom ? "ontouchstart" in window : false;
|
|
18288
18289
|
const events = isSupportTouch ? ["touchstart", "touchmove", "touchend", "touchleave"] : ["mousedown", "mousemove", "mouseup", "mouseleave"];
|
|
18289
18290
|
useEffect(() => {
|
|
@@ -18299,6 +18300,7 @@ const InternalSignature = (props, ref) => {
|
|
|
18299
18300
|
}, [isCanvasSupported]);
|
|
18300
18301
|
const startEventHandler = (event) => {
|
|
18301
18302
|
event.preventDefault();
|
|
18303
|
+
isSignedRef.current = true;
|
|
18302
18304
|
if (ctx2.current && canvasRef.current) {
|
|
18303
18305
|
ctx2.current.beginPath();
|
|
18304
18306
|
ctx2.current.lineWidth = lineWidth;
|
|
@@ -18339,6 +18341,7 @@ const InternalSignature = (props, ref) => {
|
|
|
18339
18341
|
}
|
|
18340
18342
|
};
|
|
18341
18343
|
const handleClearBtn = () => {
|
|
18344
|
+
isSignedRef.current = false;
|
|
18342
18345
|
if (canvasRef.current && ctx2.current) {
|
|
18343
18346
|
canvasRef.current.addEventListener(events[2], endEventHandler, false);
|
|
18344
18347
|
ctx2.current.clearRect(0, 0, canvasWidth, canvasHeight);
|
|
@@ -18347,7 +18350,11 @@ const InternalSignature = (props, ref) => {
|
|
|
18347
18350
|
onClear && onClear();
|
|
18348
18351
|
};
|
|
18349
18352
|
const onSave = (canvas) => {
|
|
18350
|
-
let dataurl;
|
|
18353
|
+
let dataurl = "";
|
|
18354
|
+
if (!isSignedRef.current) {
|
|
18355
|
+
onConfirm && onConfirm(canvas, dataurl, isSignedRef.current);
|
|
18356
|
+
return;
|
|
18357
|
+
}
|
|
18351
18358
|
switch (type4) {
|
|
18352
18359
|
case "png":
|
|
18353
18360
|
dataurl = canvas.toDataURL("image/png");
|
|
@@ -18358,7 +18365,7 @@ const InternalSignature = (props, ref) => {
|
|
|
18358
18365
|
default:
|
|
18359
18366
|
dataurl = canvas.toDataURL("image/png");
|
|
18360
18367
|
}
|
|
18361
|
-
onConfirm && onConfirm(canvas, dataurl);
|
|
18368
|
+
onConfirm && onConfirm(canvas, dataurl, isSignedRef.current);
|
|
18362
18369
|
};
|
|
18363
18370
|
useImperativeHandle(ref, () => ({
|
|
18364
18371
|
confirm: () => {
|
|
@@ -19229,7 +19236,8 @@ const ActionSheet = (props) => {
|
|
|
19229
19236
|
onClick: () => cancelActionSheet()
|
|
19230
19237
|
},
|
|
19231
19238
|
cancelText
|
|
19232
|
-
))
|
|
19239
|
+
)),
|
|
19240
|
+
/* @__PURE__ */ React__default.createElement("div", { className: `${classPrefix2}-safe-area` })
|
|
19233
19241
|
);
|
|
19234
19242
|
};
|
|
19235
19243
|
ActionSheet.displayName = "NutActionSheet";
|
package/dist/nutui.react.umd.js
CHANGED
|
@@ -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.
|
|
5
|
+
* @nutui/nutui-react v2.6.7 Tue May 28 2024 17:31:53 GMT+0800 (China Standard Time)
|
|
6
6
|
* (c) 2023 @jdf2e.
|
|
7
7
|
* Released under the MIT License.
|
|
8
8
|
*/
|
|
@@ -18302,6 +18302,7 @@ Please add \`${key}Action\` when creating your handler.`);
|
|
|
18302
18302
|
return !!(elem.getContext && elem.getContext("2d"));
|
|
18303
18303
|
};
|
|
18304
18304
|
const [isCanvasSupported, setIsCanvasSupported] = React.useState(false);
|
|
18305
|
+
const isSignedRef = React.useRef(false);
|
|
18305
18306
|
const isSupportTouch = canUseDom ? "ontouchstart" in window : false;
|
|
18306
18307
|
const events = isSupportTouch ? ["touchstart", "touchmove", "touchend", "touchleave"] : ["mousedown", "mousemove", "mouseup", "mouseleave"];
|
|
18307
18308
|
React.useEffect(() => {
|
|
@@ -18317,6 +18318,7 @@ Please add \`${key}Action\` when creating your handler.`);
|
|
|
18317
18318
|
}, [isCanvasSupported]);
|
|
18318
18319
|
const startEventHandler = (event) => {
|
|
18319
18320
|
event.preventDefault();
|
|
18321
|
+
isSignedRef.current = true;
|
|
18320
18322
|
if (ctx2.current && canvasRef.current) {
|
|
18321
18323
|
ctx2.current.beginPath();
|
|
18322
18324
|
ctx2.current.lineWidth = lineWidth;
|
|
@@ -18357,6 +18359,7 @@ Please add \`${key}Action\` when creating your handler.`);
|
|
|
18357
18359
|
}
|
|
18358
18360
|
};
|
|
18359
18361
|
const handleClearBtn = () => {
|
|
18362
|
+
isSignedRef.current = false;
|
|
18360
18363
|
if (canvasRef.current && ctx2.current) {
|
|
18361
18364
|
canvasRef.current.addEventListener(events[2], endEventHandler, false);
|
|
18362
18365
|
ctx2.current.clearRect(0, 0, canvasWidth, canvasHeight);
|
|
@@ -18365,7 +18368,11 @@ Please add \`${key}Action\` when creating your handler.`);
|
|
|
18365
18368
|
onClear && onClear();
|
|
18366
18369
|
};
|
|
18367
18370
|
const onSave = (canvas) => {
|
|
18368
|
-
let dataurl;
|
|
18371
|
+
let dataurl = "";
|
|
18372
|
+
if (!isSignedRef.current) {
|
|
18373
|
+
onConfirm && onConfirm(canvas, dataurl, isSignedRef.current);
|
|
18374
|
+
return;
|
|
18375
|
+
}
|
|
18369
18376
|
switch (type2) {
|
|
18370
18377
|
case "png":
|
|
18371
18378
|
dataurl = canvas.toDataURL("image/png");
|
|
@@ -18376,7 +18383,7 @@ Please add \`${key}Action\` when creating your handler.`);
|
|
|
18376
18383
|
default:
|
|
18377
18384
|
dataurl = canvas.toDataURL("image/png");
|
|
18378
18385
|
}
|
|
18379
|
-
onConfirm && onConfirm(canvas, dataurl);
|
|
18386
|
+
onConfirm && onConfirm(canvas, dataurl, isSignedRef.current);
|
|
18380
18387
|
};
|
|
18381
18388
|
React.useImperativeHandle(ref, () => ({
|
|
18382
18389
|
confirm: () => {
|
|
@@ -19247,7 +19254,8 @@ Please add \`${key}Action\` when creating your handler.`);
|
|
|
19247
19254
|
onClick: () => cancelActionSheet()
|
|
19248
19255
|
},
|
|
19249
19256
|
cancelText
|
|
19250
|
-
))
|
|
19257
|
+
)),
|
|
19258
|
+
/* @__PURE__ */ React.createElement("div", { className: `${classPrefix2}-safe-area` })
|
|
19251
19259
|
);
|
|
19252
19260
|
};
|
|
19253
19261
|
ActionSheet.displayName = "NutActionSheet";
|
|
@@ -8,7 +8,6 @@
|
|
|
8
8
|
&.nut-popup {
|
|
9
9
|
min-height: 10%;
|
|
10
10
|
background-color: $actionsheet-background-color;
|
|
11
|
-
padding: $actionsheet-padding;
|
|
12
11
|
}
|
|
13
12
|
|
|
14
13
|
.nut-popup-title {
|
|
@@ -55,4 +54,11 @@
|
|
|
55
54
|
border-top: 1px solid $actionsheet-border-color;
|
|
56
55
|
border-radius: $actionsheet-border-radius;
|
|
57
56
|
}
|
|
57
|
+
|
|
58
|
+
&-safe-area {
|
|
59
|
+
display: block;
|
|
60
|
+
width: 100%;
|
|
61
|
+
padding-bottom: constant(safe-area-inset-bottom);
|
|
62
|
+
padding-bottom: env(safe-area-inset-bottom);
|
|
63
|
+
}
|
|
58
64
|
}
|