@para-ui/core 2.1.3 → 2.1.4
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/AutoBox/index.d.ts +3 -1
- package/AutoBox/index.js +1 -1
- package/AutoTips/index.d.ts +2 -0
- package/AutoTips/index.js +1 -1
- package/Breadcrumbs/index.d.ts +11 -3
- package/Breadcrumbs/index.js +5 -5
- package/Button/index.js +8 -8
- package/ButtonGroup/index.d.ts +2 -0
- package/ButtonGroup/index.js +2 -2
- package/Checkbox/index.d.ts +3 -1
- package/Checkbox/index.js +1 -1
- package/CheckboxGroup/index.d.ts +5 -3
- package/CheckboxGroup/index.js +3 -3
- package/ComboSelect/index.js +2 -2
- package/DatePicker/PickerTag.d.ts +2 -2
- package/DatePicker/generatePicker/index.d.ts +1 -1
- package/DatePicker/index.js +35 -9
- package/Drawer/index.js +1 -1
- package/Drawer/interface.d.ts +5 -2
- package/Form/index.js +2 -2
- package/FormItem/index.js +2 -2
- package/FunctionModal/index.js +2 -2
- package/Help/index.d.ts +1 -0
- package/IconList/index.js +1 -1
- package/InputLang/index.d.ts +3 -1
- package/InputLang/index.js +2 -2
- package/InputNumber/index.js +8 -8
- package/Loading/index.d.ts +2 -2
- package/Menu/index.js +1 -1
- package/Menu/interface.d.ts +3 -1
- package/Message/index.d.ts +3 -1
- package/Message/index.js +1 -1
- package/Modal/index.d.ts +7 -1
- package/Modal/index.js +2 -2
- package/MultiBox/index.d.ts +3 -1
- package/MultiBox/index.js +2 -2
- package/PageHeader/index.js +2 -2
- package/PageHeader/interface.d.ts +3 -1
- package/Pagination/index.d.ts +3 -1
- package/Pagination/index.js +2 -2
- package/PopConfirm/index.d.ts +3 -1
- package/PopConfirm/index.js +2 -2
- package/README.md +20 -5
- package/Radio/index.d.ts +4 -2
- package/Radio/index.js +1 -1
- package/RadioGroup/index.d.ts +6 -4
- package/RadioGroup/index.js +3 -3
- package/Search/index.d.ts +2 -0
- package/Search/index.js +2 -2
- package/Select/index.d.ts +4 -2
- package/Select/index.js +2 -2
- package/SingleBox/index.d.ts +3 -1
- package/SingleBox/index.js +2 -2
- package/Slider/interface.d.ts +2 -0
- package/Switch/index.d.ts +4 -0
- package/Table/index.js +2 -2
- package/Table/interface.d.ts +5 -3
- package/Tabs/index.d.ts +2 -2
- package/Tag/index.js +7 -7
- package/TextField/index.d.ts +2 -0
- package/TextField/index.js +2 -2
- package/TimePicker/index.d.ts +1 -0
- package/TimePicker/index.js +35 -9
- package/Timeline/index.d.ts +3 -1
- package/Timeline/index.js +1 -1
- package/ToggleButton/index.js +9 -9
- package/Transfer/index.js +2 -2
- package/Tree/index.js +1 -1
- package/Upload/index.js +1 -1
- package/cdn/AutoBox/index.js +1 -1
- package/cdn/AutoTips/index.js +1 -1
- package/cdn/Breadcrumbs/index.js +28 -4
- package/cdn/Button/index.js +1 -1
- package/cdn/ButtonGroup/index.js +2 -2
- package/cdn/Checkbox/index.js +1 -1
- package/cdn/CheckboxGroup/index.js +1 -1
- package/cdn/ComboSelect/index.js +2 -2
- package/cdn/DatePicker/index.js +34 -8
- package/cdn/Drawer/index.js +1 -1
- package/cdn/Form/index.js +2 -2
- package/cdn/FormItem/index.js +2 -2
- package/cdn/FunctionModal/index.js +2 -2
- package/cdn/IconList/index.js +1 -1
- package/cdn/InputLang/index.js +4 -4
- package/cdn/InputNumber/index.js +2 -2
- package/cdn/Menu/index.js +1 -1
- package/cdn/Message/index.js +1 -1
- package/cdn/Modal/index.js +2 -2
- package/cdn/MultiBox/index.js +2 -2
- package/cdn/PageHeader/index.js +2 -2
- package/cdn/Pagination/index.js +2 -2
- package/cdn/PopConfirm/index.js +2 -2
- package/cdn/Radio/index.js +1 -1
- package/cdn/RadioGroup/index.js +1 -1
- package/cdn/Search/index.js +17 -17
- package/cdn/Select/index.js +2 -2
- package/cdn/SingleBox/index.js +2 -2
- package/cdn/Table/index.js +2 -2
- package/cdn/Tag/index.js +1 -1
- package/cdn/TextField/index.js +2 -2
- package/cdn/TimePicker/index.js +34 -8
- package/cdn/Timeline/index.js +1 -1
- package/cdn/ToggleButton/index.js +1 -1
- package/cdn/Transfer/index.js +2 -2
- package/cdn/Tree/index.js +1 -1
- package/cdn/Upload/index.js +1 -1
- package/index.js +2 -2
- package/package.json +1 -1
- package/style.css +9 -9
package/Drawer/index.js
CHANGED
|
@@ -12,4 +12,4 @@ object-assign
|
|
|
12
12
|
* This source code is licensed under the MIT license found in the
|
|
13
13
|
* LICENSE file in the root directory of this source tree.
|
|
14
14
|
*/
|
|
15
|
-
a(7418);var t=a(8156),n=60103;if(60107,"function"==typeof Symbol&&Symbol.for){var o=Symbol.for;n=o("react.element"),o("react.fragment")}var i=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,p=Object.prototype.hasOwnProperty,u={key:!0,ref:!0,__self:!0,__source:!0};function c(r,e,a){var t,o={},c=null,d=null;for(t in void 0!==a&&(c=""+a),void 0!==e.key&&(c=""+e.key),void 0!==e.ref&&(d=e.ref),e)p.call(e,t)&&!u.hasOwnProperty(t)&&(o[t]=e[t]);if(r&&r.defaultProps)for(t in e=r.defaultProps)void 0===o[t]&&(o[t]=e[t]);return{$$typeof:n,type:r,key:c,ref:d,props:o,_owner:i.current}}e.jsx=c},5893:function(r,e,a){"use strict";r.exports=a(5251)},8260:function(r,e,a){var t=a(3379),n=a(705);"string"==typeof(n=n.__esModule?n.default:n)&&(n=[[r.id,n,""]]);var o={insert:("body","body"),singleton:!1};t(n,o);r.exports=n.locals||{}},3379:function(r,e,a){"use strict";var t,n=function(){return void 0===t&&(t=Boolean(window&&document&&document.all&&!window.atob)),t},o=function(){var r={};return function(e){if(void 0===r[e]){var a=document.querySelector(e);if(window.HTMLIFrameElement&&a instanceof window.HTMLIFrameElement)try{a=a.contentDocument.head}catch(r){a=null}r[e]=a}return r[e]}}(),i=[];function p(r){for(var e=-1,a=0;a<i.length;a++)if(i[a].identifier===r){e=a;break}return e}function u(r,e){for(var a={},t=[],n=0;n<r.length;n++){var o=r[n],u=e.base?o[0]+e.base:o[0],c=a[u]||0,d="".concat(u," ").concat(c);a[u]=c+1;var s=p(d),f={css:o[1],media:o[2],sourceMap:o[3]};-1!==s?(i[s].references++,i[s].updater(f)):i.push({identifier:d,updater:
|
|
15
|
+
a(7418);var t=a(8156),n=60103;if(60107,"function"==typeof Symbol&&Symbol.for){var o=Symbol.for;n=o("react.element"),o("react.fragment")}var i=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,p=Object.prototype.hasOwnProperty,u={key:!0,ref:!0,__self:!0,__source:!0};function c(r,e,a){var t,o={},c=null,d=null;for(t in void 0!==a&&(c=""+a),void 0!==e.key&&(c=""+e.key),void 0!==e.ref&&(d=e.ref),e)p.call(e,t)&&!u.hasOwnProperty(t)&&(o[t]=e[t]);if(r&&r.defaultProps)for(t in e=r.defaultProps)void 0===o[t]&&(o[t]=e[t]);return{$$typeof:n,type:r,key:c,ref:d,props:o,_owner:i.current}}e.jsx=c},5893:function(r,e,a){"use strict";r.exports=a(5251)},8260:function(r,e,a){var t=a(3379),n=a(705);"string"==typeof(n=n.__esModule?n.default:n)&&(n=[[r.id,n,""]]);var o={insert:("body","body"),singleton:!1};t(n,o);r.exports=n.locals||{}},3379:function(r,e,a){"use strict";var t,n=function(){return void 0===t&&(t=Boolean(window&&document&&document.all&&!window.atob)),t},o=function(){var r={};return function(e){if(void 0===r[e]){var a=document.querySelector(e);if(window.HTMLIFrameElement&&a instanceof window.HTMLIFrameElement)try{a=a.contentDocument.head}catch(r){a=null}r[e]=a}return r[e]}}(),i=[];function p(r){for(var e=-1,a=0;a<i.length;a++)if(i[a].identifier===r){e=a;break}return e}function u(r,e){for(var a={},t=[],n=0;n<r.length;n++){var o=r[n],u=e.base?o[0]+e.base:o[0],c=a[u]||0,d="".concat(u," ").concat(c);a[u]=c+1;var s=p(d),f={css:o[1],media:o[2],sourceMap:o[3]};-1!==s?(i[s].references++,i[s].updater(f)):i.push({identifier:d,updater:b(f,e),references:1}),t.push(d)}return t}function c(r){var e=document.createElement("style"),t=r.attributes||{};if(void 0===t.nonce){var n=a.nc;n&&(t.nonce=n)}if(Object.keys(t).forEach((function(r){e.setAttribute(r,t[r])})),"function"==typeof r.insert)r.insert(e);else{var i=o(r.insert||"head");if(!i)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");i.appendChild(e)}return e}var d,s=(d=[],function(r,e){return d[r]=e,d.filter(Boolean).join("\n")});function f(r,e,a,t){var n=a?"":t.media?"@media ".concat(t.media," {").concat(t.css,"}"):t.css;if(r.styleSheet)r.styleSheet.cssText=s(e,n);else{var o=document.createTextNode(n),i=r.childNodes;i[e]&&r.removeChild(i[e]),i.length?r.insertBefore(o,i[e]):r.appendChild(o)}}function l(r,e,a){var t=a.css,n=a.media,o=a.sourceMap;if(n?r.setAttribute("media",n):r.removeAttribute("media"),o&&"undefined"!=typeof btoa&&(t+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(o))))," */")),r.styleSheet)r.styleSheet.cssText=t;else{for(;r.firstChild;)r.removeChild(r.firstChild);r.appendChild(document.createTextNode(t))}}var w=null,h=0;function b(r,e){var a,t,n;if(e.singleton){var o=h++;a=w||(w=c(e)),t=f.bind(null,a,o,!1),n=f.bind(null,a,o,!0)}else a=c(e),t=l.bind(null,a,e),n=function(){!function(r){if(null===r.parentNode)return!1;r.parentNode.removeChild(r)}(a)};return t(r),function(e){if(e){if(e.css===r.css&&e.media===r.media&&e.sourceMap===r.sourceMap)return;t(r=e)}else n()}}r.exports=function(r,e){(e=e||{}).singleton||"boolean"==typeof e.singleton||(e.singleton=n());var a=u(r=r||[],e);return function(r){if(r=r||[],"[object Array]"===Object.prototype.toString.call(r)){for(var t=0;t<a.length;t++){var n=p(a[t]);i[n].references--}for(var o=u(r,e),c=0;c<a.length;c++){var d=p(a[c]);0===i[d].references&&(i[d].updater(),i.splice(d,1))}a=o}}}},8543:function(r){"use strict";r.exports=a},5534:function(r){"use strict";r.exports=e},8156:function(e){"use strict";e.exports=r}},n={};function o(r){var e=n[r];if(void 0!==e)return e.exports;var a=n[r]={id:r,exports:{}};return t[r](a,a.exports,o),a.exports}o.n=function(r){var e=r&&r.__esModule?function(){return r.default}:function(){return r};return o.d(e,{a:e}),e},o.d=function(r,e){for(var a in e)o.o(e,a)&&!o.o(r,a)&&Object.defineProperty(r,a,{enumerable:!0,get:e[a]})},o.o=function(r,e){return Object.prototype.hasOwnProperty.call(r,e)},o.r=function(r){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(r,"__esModule",{value:!0})};var i={};return function(){"use strict";o.r(i),o.d(i,{Drawer:function(){return s}});var r=o(5893),e=o(8156),a=o.n(e),t=o(5534),n=o.n(t),p=o(6010),u=o(8543),c=(o(8260),function(){return c=Object.assign||function(r){for(var e,a=1,t=arguments.length;a<t;a++)for(var n in e=arguments[a])Object.prototype.hasOwnProperty.call(e,n)&&(r[n]=e[n]);return r},c.apply(this,arguments)}),d=function(r,e){var a={};for(var t in r)Object.prototype.hasOwnProperty.call(r,t)&&e.indexOf(t)<0&&(a[t]=r[t]);if(null!=r&&"function"==typeof Object.getOwnPropertySymbols){var n=0;for(t=Object.getOwnPropertySymbols(r);n<t.length;n++)e.indexOf(t[n])<0&&Object.prototype.propertyIsEnumerable.call(r,t[n])&&(a[t[n]]=r[t[n]])}return a},s=function(e){e.className;var t=e.onClose,o=e.destroyOnClose,i=void 0!==o&&o,s=e.style,f=d(e,["className","onClose","destroyOnClose","style"]),l=a().useState((0,u.UUID)()),w=l[0],h=l[1];return(0,r.jsx)(n(),c({},f,function(){if(!e.open)return{};var r={};if("left"===e.placement||"right"===e.placement){var a="large"===e.size?736:378;r.width=void 0===e.width?a:e.width}else{var t="large"===e.size?736:378;r.height=void 0===e.height?t:e.height}return r}(),{style:s,prefixCls:"paraui-drawer",className:(0,p.Z)("paraui-drawer",e.className),onClose:function(r){null==t||t(r),i&&setTimeout((function(){h((0,u.UUID)())}),500)}}),w)};s.defaultProps={level:null,handler:!1,size:"default",showMask:!0,placement:"right"},i.default=s}(),i}()}));
|
package/Drawer/interface.d.ts
CHANGED
|
@@ -22,6 +22,8 @@ export interface DrawerProps {
|
|
|
22
22
|
handler?: React.ReactElement | null | false;
|
|
23
23
|
/** 抽屉的方向 */
|
|
24
24
|
placement?: IPlacement;
|
|
25
|
+
/** 预设抽屉宽度(或高度),default 378px 和 large 736px */
|
|
26
|
+
size?: 'default' | 'large';
|
|
25
27
|
/** 层级元素 */
|
|
26
28
|
level?: null | string | string[];
|
|
27
29
|
/** 层级移动值 */
|
|
@@ -39,15 +41,16 @@ export interface DrawerProps {
|
|
|
39
41
|
maskClosable?: boolean;
|
|
40
42
|
/** 遮罩样式 */
|
|
41
43
|
maskStyle?: React.CSSProperties;
|
|
44
|
+
style?: React.CSSProperties;
|
|
42
45
|
/** 变化时回调 */
|
|
43
|
-
onChange?: (open
|
|
46
|
+
onChange?: (open: boolean) => void;
|
|
44
47
|
/** transition end 回调 */
|
|
45
48
|
afterVisibleChange?: (open: boolean) => void;
|
|
46
49
|
/** handle 点击*/
|
|
47
50
|
onHandleClick?: (event: React.MouseEvent | React.KeyboardEvent) => void;
|
|
48
51
|
/** 关闭时回调 */
|
|
49
52
|
onClose?: (event: React.MouseEvent | React.KeyboardEvent) => void;
|
|
50
|
-
/** 是否支持键盘 */
|
|
53
|
+
/** 是否支持键盘 esc 关闭 */
|
|
51
54
|
keyboard?: boolean;
|
|
52
55
|
/** 内容包裹样式 */
|
|
53
56
|
contentWrapperStyle?: React.CSSProperties;
|