@kdcloudjs/kdesign 1.8.29 → 1.8.31

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.
Files changed (171) hide show
  1. package/dist/kdesign-complete.less +897 -83
  2. package/dist/kdesign.css +650 -7
  3. package/dist/kdesign.css.map +1 -1
  4. package/dist/kdesign.js +188 -109
  5. package/dist/kdesign.js.map +1 -1
  6. package/dist/kdesign.min.css +3 -3
  7. package/dist/kdesign.min.js +5 -5
  8. package/dist/kdesign.min.js.map +1 -1
  9. package/es/anchor/anchor.js +7 -5
  10. package/es/anchor/style/index.css +14 -0
  11. package/es/anchor/style/index.less +15 -0
  12. package/es/button/button.js +4 -2
  13. package/es/button/group.js +5 -3
  14. package/es/button/style/index.css +32 -0
  15. package/es/button/style/index.less +42 -1
  16. package/es/checkbox/checkbox.js +5 -3
  17. package/es/checkbox/group.js +4 -2
  18. package/es/checkbox/style/index.css +38 -1
  19. package/es/checkbox/style/index.less +56 -15
  20. package/es/city-picker/city-picker.js +32 -14
  21. package/es/city-picker/option.js +7 -2
  22. package/es/city-picker/style/index.css +54 -0
  23. package/es/city-picker/style/index.less +67 -0
  24. package/es/collapse/collapse.js +4 -2
  25. package/es/collapse/style/index.css +24 -0
  26. package/es/collapse/style/index.less +26 -0
  27. package/es/color-picker/color-picker.js +6 -4
  28. package/es/color-picker/style/index.css +129 -4
  29. package/es/color-picker/style/index.less +174 -29
  30. package/es/config-provider/ConfigContext.d.ts +4 -0
  31. package/es/config-provider/ConfigContext.js +2 -0
  32. package/es/config-provider/compDefaultProps.d.ts +0 -1
  33. package/es/config-provider/compDefaultProps.js +0 -5
  34. package/es/config-provider/defaultConfig.d.ts +1 -0
  35. package/es/config-provider/defaultConfig.js +2 -1
  36. package/es/dropdown/dropdown.js +4 -2
  37. package/es/dropdown/menu.js +4 -2
  38. package/es/dropdown/style/index.css +3 -0
  39. package/es/dropdown/style/index.less +4 -0
  40. package/es/image/preview.js +6 -4
  41. package/es/image/style/index.css +11 -0
  42. package/es/image/style/index.less +20 -4
  43. package/es/input/ClearableLabeledInput.d.ts +1 -0
  44. package/es/input/ClearableLabeledInput.js +6 -4
  45. package/es/input/TextArea.js +7 -4
  46. package/es/input/input.js +6 -3
  47. package/es/input/style/index.css +48 -0
  48. package/es/input/style/index.less +55 -0
  49. package/es/link/link.js +4 -2
  50. package/es/link/style/index.css +11 -0
  51. package/es/link/style/index.less +14 -0
  52. package/es/menu/menu.js +4 -2
  53. package/es/menu/menuItem.js +5 -3
  54. package/es/menu/style/index.css +10 -0
  55. package/es/menu/style/index.less +33 -22
  56. package/es/menu/subMenu.js +6 -4
  57. package/es/modal/modal.js +4 -2
  58. package/es/modal/style/index.css +7 -0
  59. package/es/modal/style/index.less +14 -0
  60. package/es/pagination/pagination.js +16 -13
  61. package/es/pagination/style/index.css +72 -0
  62. package/es/pagination/style/index.less +99 -0
  63. package/es/qr-code/qr-code.js +4 -2
  64. package/es/qr-code/style/index.css +3 -0
  65. package/es/qr-code/style/index.less +7 -3
  66. package/es/radio/group.js +4 -2
  67. package/es/radio/radio.js +4 -2
  68. package/es/radio/style/index.css +38 -0
  69. package/es/radio/style/index.less +46 -0
  70. package/es/select/option.js +4 -2
  71. package/es/select/select.js +8 -6
  72. package/es/select/style/index.css +61 -0
  73. package/es/select/style/index.less +87 -0
  74. package/es/steps/Steps.js +4 -2
  75. package/es/steps/style/index.css +35 -0
  76. package/es/steps/style/index.less +59 -5
  77. package/es/switch/style/index.css +9 -0
  78. package/es/switch/style/index.less +9 -2
  79. package/es/switch/switch.js +4 -2
  80. package/es/tag/style/index.css +7 -0
  81. package/es/tag/style/index.less +8 -0
  82. package/es/tag/tag.js +4 -2
  83. package/es/tree/style/index.css +19 -0
  84. package/es/tree/style/index.less +27 -0
  85. package/es/tree/tree.js +4 -2
  86. package/es/tree/treeNode.js +3 -2
  87. package/es/upload/style/index.css +24 -1
  88. package/es/upload/style/index.less +40 -2
  89. package/es/upload/upload.js +4 -2
  90. package/lib/anchor/anchor.js +7 -5
  91. package/lib/anchor/style/index.css +14 -0
  92. package/lib/anchor/style/index.less +15 -0
  93. package/lib/button/button.js +4 -2
  94. package/lib/button/group.js +5 -3
  95. package/lib/button/style/index.css +32 -0
  96. package/lib/button/style/index.less +42 -1
  97. package/lib/checkbox/checkbox.js +5 -3
  98. package/lib/checkbox/group.js +4 -2
  99. package/lib/checkbox/style/index.css +38 -1
  100. package/lib/checkbox/style/index.less +56 -15
  101. package/lib/city-picker/city-picker.js +32 -14
  102. package/lib/city-picker/option.js +7 -2
  103. package/lib/city-picker/style/index.css +54 -0
  104. package/lib/city-picker/style/index.less +67 -0
  105. package/lib/collapse/collapse.js +4 -2
  106. package/lib/collapse/style/index.css +24 -0
  107. package/lib/collapse/style/index.less +26 -0
  108. package/lib/color-picker/color-picker.js +6 -4
  109. package/lib/color-picker/style/index.css +129 -4
  110. package/lib/color-picker/style/index.less +174 -29
  111. package/lib/config-provider/ConfigContext.d.ts +4 -0
  112. package/lib/config-provider/ConfigContext.js +4 -1
  113. package/lib/config-provider/compDefaultProps.d.ts +0 -1
  114. package/lib/config-provider/compDefaultProps.js +0 -5
  115. package/lib/config-provider/defaultConfig.d.ts +1 -0
  116. package/lib/config-provider/defaultConfig.js +2 -1
  117. package/lib/dropdown/dropdown.js +4 -2
  118. package/lib/dropdown/menu.js +4 -2
  119. package/lib/dropdown/style/index.css +3 -0
  120. package/lib/dropdown/style/index.less +4 -0
  121. package/lib/image/preview.js +6 -4
  122. package/lib/image/style/index.css +11 -0
  123. package/lib/image/style/index.less +20 -4
  124. package/lib/input/ClearableLabeledInput.d.ts +1 -0
  125. package/lib/input/ClearableLabeledInput.js +6 -4
  126. package/lib/input/TextArea.js +7 -4
  127. package/lib/input/input.js +6 -3
  128. package/lib/input/style/index.css +48 -0
  129. package/lib/input/style/index.less +55 -0
  130. package/lib/link/link.js +4 -2
  131. package/lib/link/style/index.css +11 -0
  132. package/lib/link/style/index.less +14 -0
  133. package/lib/menu/menu.js +4 -2
  134. package/lib/menu/menuItem.js +5 -3
  135. package/lib/menu/style/index.css +10 -0
  136. package/lib/menu/style/index.less +33 -22
  137. package/lib/menu/subMenu.js +6 -4
  138. package/lib/modal/modal.js +4 -2
  139. package/lib/modal/style/index.css +7 -0
  140. package/lib/modal/style/index.less +14 -0
  141. package/lib/pagination/pagination.js +16 -13
  142. package/lib/pagination/style/index.css +72 -0
  143. package/lib/pagination/style/index.less +99 -0
  144. package/lib/qr-code/qr-code.js +4 -2
  145. package/lib/qr-code/style/index.css +3 -0
  146. package/lib/qr-code/style/index.less +7 -3
  147. package/lib/radio/group.js +4 -2
  148. package/lib/radio/radio.js +4 -2
  149. package/lib/radio/style/index.css +38 -0
  150. package/lib/radio/style/index.less +46 -0
  151. package/lib/select/option.js +4 -2
  152. package/lib/select/select.js +8 -6
  153. package/lib/select/style/index.css +61 -0
  154. package/lib/select/style/index.less +87 -0
  155. package/lib/steps/Steps.js +4 -2
  156. package/lib/steps/style/index.css +35 -0
  157. package/lib/steps/style/index.less +59 -5
  158. package/lib/switch/style/index.css +9 -0
  159. package/lib/switch/style/index.less +9 -2
  160. package/lib/switch/switch.js +4 -2
  161. package/lib/tag/style/index.css +7 -0
  162. package/lib/tag/style/index.less +8 -0
  163. package/lib/tag/tag.js +4 -2
  164. package/lib/tree/style/index.css +19 -0
  165. package/lib/tree/style/index.less +27 -0
  166. package/lib/tree/tree.js +4 -2
  167. package/lib/tree/treeNode.js +3 -2
  168. package/lib/upload/style/index.css +24 -1
  169. package/lib/upload/style/index.less +40 -2
  170. package/lib/upload/upload.js +4 -2
  171. package/package.json +1 -1
@@ -39,7 +39,8 @@ var InternalTextarea = function InternalTextarea(props, ref) {
39
39
  var _useContext = (0, _react.useContext)(_ConfigContext.default),
40
40
  getPrefixCls = _useContext.getPrefixCls,
41
41
  prefixCls = _useContext.prefixCls,
42
- userDefaultProps = _useContext.compDefaultProps;
42
+ userDefaultProps = _useContext.compDefaultProps,
43
+ direction = _useContext.direction;
43
44
  var textAreaProps = (0, _utils.getCompProps)('TextArea', userDefaultProps, props);
44
45
  var _useState = (0, _react.useState)({}),
45
46
  _useState2 = (0, _slicedToArray2.default)(_useState, 2),
@@ -70,6 +71,7 @@ var InternalTextarea = function InternalTextarea(props, ref) {
70
71
  addonBefore = textAreaProps.addonBefore,
71
72
  others = __rest(textAreaProps, ["value", "allowClear", "borderType", "defaultValue", "count", "countPosition", "autoSize", "className", "prefixCls", "canResize", "maxLength", "disabled", "onBlur", "onFocus", "onChange", "placeholder", "style", "size", "status", "prefix", "suffix", "addonAfter", "addonBefore"]);
72
73
  var textAreaPrefixCls = getPrefixCls(prefixCls, 'input', customPrefixcls);
74
+ var rtlCls = direction === 'rtl' ? "".concat(textAreaPrefixCls, "-rtl") : null;
73
75
  (0, _devwarning.default)(_input.BorderTypes.indexOf(borderType) === -1, 'textarea', "cannot found textarea borderType '".concat(borderType, "'"));
74
76
  var _useMergedState = (0, _hooks.useMergedState)('', {
75
77
  value: propsValue,
@@ -191,7 +193,7 @@ var InternalTextarea = function InternalTextarea(props, ref) {
191
193
  ref: textareaRef,
192
194
  disabled: disabled,
193
195
  style: (0, _extends2.default)({}, textareaStyles, hadCount || !!allowClear ? otherStyles : style),
194
- className: (0, _classnames.default)("".concat(prefixCls, "-textarea"), (_classNames2 = {}, (0, _defineProperty2.default)(_classNames2, (0, _concat.default)(_context = "".concat(prefixCls, "-size-")).call(_context, size), size), (0, _defineProperty2.default)(_classNames2, "".concat(prefixCls, "-borderless"), borderType === 'none'), (0, _defineProperty2.default)(_classNames2, "".concat(prefixCls, "-underline"), borderType === 'underline'), (0, _defineProperty2.default)(_classNames2, "".concat(prefixCls, "-no-resize"), canResize !== true), (0, _defineProperty2.default)(_classNames2, "".concat(prefixCls, "-allowClear-spacing"), !!allowClear), (0, _defineProperty2.default)(_classNames2, "".concat(prefixCls, "-error"), status === 'error' || numberMarkError), (0, _defineProperty2.default)(_classNames2, "".concat(prefixCls, "-disabled"), disabled), _classNames2), (0, _defineProperty2.default)({}, className, className && !allowClear && !hadCount)),
196
+ className: (0, _classnames.default)("".concat(prefixCls, "-textarea"), rtlCls, (_classNames2 = {}, (0, _defineProperty2.default)(_classNames2, (0, _concat.default)(_context = "".concat(prefixCls, "-size-")).call(_context, size), size), (0, _defineProperty2.default)(_classNames2, "".concat(prefixCls, "-borderless"), borderType === 'none'), (0, _defineProperty2.default)(_classNames2, "".concat(prefixCls, "-underline"), borderType === 'underline'), (0, _defineProperty2.default)(_classNames2, "".concat(prefixCls, "-no-resize"), canResize !== true), (0, _defineProperty2.default)(_classNames2, "".concat(prefixCls, "-allowClear-spacing"), !!allowClear), (0, _defineProperty2.default)(_classNames2, "".concat(prefixCls, "-error"), status === 'error' || numberMarkError), (0, _defineProperty2.default)(_classNames2, "".concat(prefixCls, "-disabled"), disabled), _classNames2), (0, _defineProperty2.default)({}, className, className && !allowClear && !hadCount)),
195
197
  onChange: handleChange,
196
198
  onFocus: !disabled ? handleFocus : undefined,
197
199
  onBlur: !disabled ? handleBlur : undefined,
@@ -201,7 +203,7 @@ var InternalTextarea = function InternalTextarea(props, ref) {
201
203
  }, others));
202
204
  return hadCount ? _react.default.createElement("span", {
203
205
  style: wrapperStyle,
204
- className: (0, _concat.default)(_context2 = "".concat(prefixCls, "-countWrapper ")).call(_context2, className && !allowClear ? className : '')
206
+ className: (0, _classnames.default)(rtlCls, (0, _concat.default)(_context2 = "".concat(prefixCls, "-countWrapper ")).call(_context2, className && !allowClear ? className : ''))
205
207
  }, textarea, renderNumberMark()) : textarea;
206
208
  };
207
209
  return _react.default.createElement(_ClearableLabeledInput.default, (0, _extends2.default)({}, textAreaProps, {
@@ -215,7 +217,8 @@ var InternalTextarea = function InternalTextarea(props, ref) {
215
217
  inputType: "text",
216
218
  prefixCls: textAreaPrefixCls,
217
219
  element: renderTextArea(textAreaPrefixCls),
218
- numberMark: renderNumberMark()
220
+ numberMark: renderNumberMark(),
221
+ direction: direction
219
222
  }));
220
223
  };
221
224
  var TextArea = _react.default.forwardRef(InternalTextarea);
@@ -47,7 +47,8 @@ var InternalInput = function InternalInput(props, ref) {
47
47
  var _useContext = (0, _react.useContext)(_ConfigContext.default),
48
48
  getPrefixCls = _useContext.getPrefixCls,
49
49
  prefixCls = _useContext.prefixCls,
50
- userDefaultProps = _useContext.compDefaultProps;
50
+ userDefaultProps = _useContext.compDefaultProps,
51
+ direction = _useContext.direction;
51
52
  var inputProps = (0, _utils.getCompProps)('Input', userDefaultProps, props);
52
53
  var type = inputProps.type,
53
54
  size = inputProps.size,
@@ -90,7 +91,8 @@ var InternalInput = function InternalInput(props, ref) {
90
91
  setShowNumberMark = _useState4[1];
91
92
  var inputRef = (0, _react.useRef)();
92
93
  var inputPrefixCls = getPrefixCls(prefixCls, 'input', customPrefixcls);
93
- var inputClasses = (0, _classnames.default)(inputPrefixCls, (_classNames = {}, (0, _defineProperty2.default)(_classNames, (0, _concat.default)(_context = "".concat(inputPrefixCls, "-size-")).call(_context, size), size), (0, _defineProperty2.default)(_classNames, "".concat(inputPrefixCls, "-borderless"), borderType === 'none'), (0, _defineProperty2.default)(_classNames, "".concat(inputPrefixCls, "-underline"), borderType === 'underline'), (0, _defineProperty2.default)(_classNames, "".concat(inputPrefixCls, "-error"), status === 'error'), (0, _defineProperty2.default)(_classNames, "".concat(inputPrefixCls, "-disabled"), disabled), _classNames), (0, _defineProperty2.default)({}, className, className && !(0, _ClearableLabeledInput.hasPrefixSuffix)(inputProps) && !addonBefore && !addonAfter));
94
+ var rtlCls = direction === 'rtl' ? "".concat(inputPrefixCls, "-rtl") : null;
95
+ var inputClasses = (0, _classnames.default)(inputPrefixCls, rtlCls, (_classNames = {}, (0, _defineProperty2.default)(_classNames, (0, _concat.default)(_context = "".concat(inputPrefixCls, "-size-")).call(_context, size), size), (0, _defineProperty2.default)(_classNames, "".concat(inputPrefixCls, "-borderless"), borderType === 'none'), (0, _defineProperty2.default)(_classNames, "".concat(inputPrefixCls, "-underline"), borderType === 'underline'), (0, _defineProperty2.default)(_classNames, "".concat(inputPrefixCls, "-error"), status === 'error'), (0, _defineProperty2.default)(_classNames, "".concat(inputPrefixCls, "-disabled"), disabled), _classNames), (0, _defineProperty2.default)({}, className, className && !(0, _ClearableLabeledInput.hasPrefixSuffix)(inputProps) && !addonBefore && !addonAfter));
94
96
  var handleFocus = function handleFocus(event) {
95
97
  setFocused(true);
96
98
  onFocus && onFocus(event);
@@ -191,7 +193,8 @@ var InternalInput = function InternalInput(props, ref) {
191
193
  element: renderInput(),
192
194
  focused: focused,
193
195
  count: count,
194
- inputCount: renderCount()
196
+ inputCount: renderCount(),
197
+ direction: direction
195
198
  }));
196
199
  };
197
200
  var Input = _react.default.forwardRef(InternalInput);
@@ -632,3 +632,51 @@ textarea {
632
632
  .kd-input-error:not(.kd-input-disabled):not(.kd-input-wrapper-disabled):not( .kd-input-group-addon-disabled) {
633
633
  border-color: var(--kd-c-input-color-error, var(--kd-g-color-error, #fb2323));
634
634
  }
635
+ .kd-input-rtl {
636
+ direction: rtl;
637
+ }
638
+ .kd-input-rtl.kd-input-group .kd-input-group-addon:first-child {
639
+ border-top-left-radius: 0;
640
+ border-bottom-left-radius: 0;
641
+ border-top-right-radius: var(--kd-c-input-radius-border, var(--kd-g-radius-border, 2px));
642
+ border-bottom-right-radius: var(--kd-c-input-radius-border, var(--kd-g-radius-border, 2px));
643
+ border-left: none;
644
+ border-right: 1px solid var(--kd-c-input-color-border-disabled, var(--kd-g-color-border-strong, #d9d9d9));
645
+ }
646
+ .kd-input-rtl.kd-input-group .kd-input-group-addon:last-child {
647
+ border-top-right-radius: 0;
648
+ border-bottom-right-radius: 0;
649
+ border-top-left-radius: var(--kd-c-input-radius-border, var(--kd-g-radius-border, 2px));
650
+ border-bottom-left-radius: var(--kd-c-input-radius-border, var(--kd-g-radius-border, 2px));
651
+ border-right: none;
652
+ border-left: 1px solid var(--kd-c-input-color-border-disabled, var(--kd-g-color-border-strong, #d9d9d9));
653
+ }
654
+ .kd-input-rtl.kd-input-wrapper .kd-input-prefix {
655
+ margin-right: 0;
656
+ margin-left: calc(var(--kd-c-input-spacing-padding-vertical-small, 3px) * 2);
657
+ }
658
+ .kd-input-rtl.kd-input-wrapper .kd-input-suffix {
659
+ margin-left: 0;
660
+ margin-right: calc(var(--kd-c-input-spacing-padding-vertical-small, 3px) * 2);
661
+ }
662
+ .kd-input-rtl.kd-input-wrapper .kd-input-clear-icon-rightSpace {
663
+ margin-left: 4px;
664
+ margin-right: 0;
665
+ }
666
+ .kd-input-rtl .kd-input-textarea-mark {
667
+ right: auto;
668
+ left: 2px;
669
+ }
670
+ .kd-input-rtl .kd-input-textarea-mark-inner {
671
+ top: auto;
672
+ left: 8px;
673
+ right: auto;
674
+ }
675
+ .kd-input-rtl .kd-input-textarea-clear-icon {
676
+ left: 8px;
677
+ right: auto;
678
+ }
679
+ .kd-input-rtl.kd-input-allowClear-spacing {
680
+ padding-right: var(--kd-c-input-spacing-padding-horizontal-small, 9px);
681
+ padding-left: 20px;
682
+ }
@@ -313,3 +313,58 @@ textarea {
313
313
  border-color: @input-error-color;
314
314
  }
315
315
  }
316
+
317
+ .@{input-prefix-cls}-rtl {
318
+ direction: rtl;
319
+ &.@{input-prefix-cls}-group {
320
+ .@{input-prefix-cls}-group-addon {
321
+ &:first-child {
322
+ border-top-left-radius: 0;
323
+ border-bottom-left-radius: 0;
324
+ border-top-right-radius: @input-border-radius-inner;
325
+ border-bottom-right-radius: @input-border-radius-inner;
326
+ border-left: none;
327
+ border-right: 1px solid @input-border-color-disabled-inner;
328
+ }
329
+ &:last-child {
330
+ border-top-right-radius: 0;
331
+ border-bottom-right-radius: 0;
332
+ border-top-left-radius: @input-border-radius-inner;
333
+ border-bottom-left-radius: @input-border-radius-inner;
334
+ border-right: none;
335
+ border-left: 1px solid @input-border-color-disabled-inner;
336
+ }
337
+ }
338
+ }
339
+ &.@{input-prefix-cls}-wrapper {
340
+ .@{input-prefix-cls}-prefix {
341
+ margin-right: 0;
342
+ margin-left: calc(@input-small-padding-vertical-inner * 2);
343
+ }
344
+ .@{input-prefix-cls}-suffix {
345
+ margin-left: 0;
346
+ margin-right: calc(@input-small-padding-vertical-inner * 2);
347
+ }
348
+ .@{input-prefix-cls}-clear-icon-rightSpace {
349
+ margin-left: 4px;
350
+ margin-right: 0;
351
+ }
352
+ }
353
+ .@{input-prefix-cls}-textarea-mark {
354
+ right: auto;
355
+ left: 2px;
356
+ &-inner {
357
+ top: auto;
358
+ left: 8px;
359
+ right: auto;
360
+ }
361
+ }
362
+ .@{input-prefix-cls}-textarea-clear-icon {
363
+ left: 8px;
364
+ right: auto;
365
+ }
366
+ &.@{input-prefix-cls}-allowClear-spacing {
367
+ padding-right: @input-small-padding-horizontal-inner;
368
+ padding-left: 20px;
369
+ }
370
+ }
package/lib/link/link.js CHANGED
@@ -34,7 +34,8 @@ var InternalLink = function InternalLink(props, ref) {
34
34
  var _useContext = (0, _react.useContext)(_ConfigContext.default),
35
35
  getPrefixCls = _useContext.getPrefixCls,
36
36
  prefixCls = _useContext.prefixCls,
37
- userDefaultProps = _useContext.compDefaultProps;
37
+ userDefaultProps = _useContext.compDefaultProps,
38
+ direction = _useContext.direction;
38
39
  var linkProps = (0, _utils.getCompProps)('Link', userDefaultProps, props);
39
40
  var size = linkProps.size,
40
41
  style = linkProps.style,
@@ -51,7 +52,8 @@ var InternalLink = function InternalLink(props, ref) {
51
52
  others = __rest(linkProps, ["size", "style", "className", "target", "href", "underscore", "children", "prefix", "suffix", "disabled", "onClick", "prefixCls"]);
52
53
  var linkRef = ref || _react.default.createRef();
53
54
  var linkPrefixCls = getPrefixCls(prefixCls, 'link', customPrefixcls);
54
- var wrapperClasses = (0, _classnames.default)((_classNames = {}, (0, _defineProperty2.default)(_classNames, "".concat(linkPrefixCls), true), (0, _defineProperty2.default)(_classNames, (0, _concat.default)(_context = "".concat(linkPrefixCls, "-size-")).call(_context, size), size), _classNames));
55
+ var rtlCls = direction === 'rtl' ? "".concat(linkPrefixCls, "-rtl") : null;
56
+ var wrapperClasses = (0, _classnames.default)(rtlCls, (_classNames = {}, (0, _defineProperty2.default)(_classNames, "".concat(linkPrefixCls), true), (0, _defineProperty2.default)(_classNames, (0, _concat.default)(_context = "".concat(linkPrefixCls, "-size-")).call(_context, size), size), _classNames));
55
57
  var linkClasses = (0, _classnames.default)(className, (_classNames2 = {}, (0, _defineProperty2.default)(_classNames2, "".concat(linkPrefixCls, "-text"), true), (0, _defineProperty2.default)(_classNames2, "".concat(linkPrefixCls, "-underscore"), underscore), (0, _defineProperty2.default)(_classNames2, "".concat(linkPrefixCls, "-disabled"), disabled), _classNames2));
56
58
  var handleClick = function handleClick(e) {
57
59
  disabled && e.preventDefault();
@@ -155,3 +155,14 @@
155
155
  display: inline-block;
156
156
  margin-left: var(--kd-c-link-suffix-horizontal, 4px);
157
157
  }
158
+ .kd-link-rtl {
159
+ direction: rtl;
160
+ }
161
+ .kd-link-rtl .kd-link-prefix {
162
+ margin-right: 0;
163
+ margin-left: var(--kd-c-link-prefix-horizontal, 4px);
164
+ }
165
+ .kd-link-rtl .kd-link-suffix {
166
+ margin-left: 0;
167
+ margin-right: var(--kd-c-link-suffix-horizontal, 4px);
168
+ }
@@ -59,3 +59,17 @@
59
59
  margin-left: @link-suffix-horizontal;
60
60
  }
61
61
  }
62
+
63
+ .@{link-prefix-cls}-rtl {
64
+ direction: rtl;
65
+ .@{link-prefix-cls} {
66
+ &-prefix {
67
+ margin-right: 0;
68
+ margin-left: @link-prefix-horizontal;
69
+ }
70
+ &-suffix {
71
+ margin-left: 0;
72
+ margin-right: @link-suffix-horizontal;
73
+ }
74
+ }
75
+ }
package/lib/menu/menu.js CHANGED
@@ -44,7 +44,8 @@ var Menu = function Menu(props) {
44
44
  var _useContext = (0, _react.useContext)(_configProvider.ConfigContext),
45
45
  getPrefixCls = _useContext.getPrefixCls,
46
46
  pkgPrefixCls = _useContext.prefixCls,
47
- userDefaultProps = _useContext.compDefaultProps;
47
+ userDefaultProps = _useContext.compDefaultProps,
48
+ direction = _useContext.direction;
48
49
  var userSelectedKey = props.selectedKey,
49
50
  userOpenKeys = props.openKeys;
50
51
  var _b = (0, _utils.getCompProps)('Menu', userDefaultProps, props),
@@ -63,6 +64,7 @@ var Menu = function Menu(props) {
63
64
  defaultOpenKeys = _b.defaultOpenKeys,
64
65
  restProps = __rest(_b, ["prefixCls", "mode", "inlineIndent", "forceSubMenuRender", "additionalTools", "onClick", "onOpenChange", "children", "className", "theme", "collapsed", "accordion", "defaultOpenKeys"]);
65
66
  var prefixCls = getPrefixCls(pkgPrefixCls, 'menu', customPrefixcls);
67
+ var rtlCls = direction === 'rtl' ? "".concat(prefixCls, "-rtl") : null;
66
68
  (0, _devwarning.default)(['inline', 'vertical', undefined].indexOf(mode) === -1, 'menu', "cannot found menu mode '".concat(mode, "'"));
67
69
  (0, _devwarning.default)(mode !== 'inline' && accordion !== undefined, 'menu', "'accordion' is valid only in mode='inline'");
68
70
  var _useState = (0, _react.useState)(''),
@@ -181,7 +183,7 @@ var Menu = function Menu(props) {
181
183
  onMouseEnter: handleMouseEnterMenu
182
184
  };
183
185
  return _react.default.createElement("div", (0, _extends2.default)({
184
- className: (0, _classnames.default)(prefixCls, className, (_classNames = {}, (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-inline"), mode === 'inline'), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-vertical"), mode !== 'inline'), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-collapsed"), collapsed), (0, _defineProperty2.default)(_classNames, (0, _concat.default)(_context2 = "".concat(prefixCls, "-")).call(_context2, theme === 'light' ? 'light' : 'dark'), true), _classNames)),
186
+ className: (0, _classnames.default)(prefixCls, rtlCls, className, (_classNames = {}, (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-inline"), mode === 'inline'), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-vertical"), mode !== 'inline'), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-collapsed"), collapsed), (0, _defineProperty2.default)(_classNames, (0, _concat.default)(_context2 = "".concat(prefixCls, "-")).call(_context2, theme === 'light' ? 'light' : 'dark'), true), _classNames)),
185
187
  role: "menu",
186
188
  style: style
187
189
  }, mouseEvent), children && renderMenu(), additionalTools);
@@ -36,7 +36,8 @@ var InternalMenuItem = function InternalMenuItem(props, ref) {
36
36
  var _React$useContext = React.useContext(_configProvider.ConfigContext),
37
37
  getPrefixCls = _React$useContext.getPrefixCls,
38
38
  pkgPrefixCls = _React$useContext.prefixCls,
39
- userDefaultProps = _React$useContext.compDefaultProps;
39
+ userDefaultProps = _React$useContext.compDefaultProps,
40
+ direction = _React$useContext.direction;
40
41
  var _a = (0, _utils.getCompProps)('MenuItem', userDefaultProps, props),
41
42
  customPrefixcls = _a.prefixCls,
42
43
  icon = _a.icon,
@@ -110,9 +111,10 @@ var InternalMenuItem = function InternalMenuItem(props, ref) {
110
111
  onMouseLeave: handleOnMouseLeave,
111
112
  onMouseEnter: handleOnMouseEnter
112
113
  };
114
+ var isRtl = direction === 'rtl';
113
115
  var titleStyle = {
114
- paddingLeft: "".concat(getPaddingLeft(), "px"),
115
- paddingRight: mode !== 'inline' && level > 1 ? "".concat(_util.DEFAUTL_PADDING, "px") : 0
116
+ paddingLeft: isRtl ? mode !== 'inline' && level > 1 ? "".concat(_util.DEFAUTL_PADDING, "px") : 0 : "".concat(getPaddingLeft(), "px"),
117
+ paddingRight: isRtl ? "".concat(getPaddingLeft(), "px") : mode !== 'inline' && level > 1 ? "".concat(_util.DEFAUTL_PADDING, "px") : 0
116
118
  };
117
119
  var renderTitle = function renderTitle() {
118
120
  if (!icon && collapsed && level === 1 && typeof children === 'string') {
@@ -627,3 +627,13 @@
627
627
  color: var(--kd-c-menu-light-color-text-active, var(--kd-g-color-theme, #5582f3));
628
628
  border: none;
629
629
  }
630
+ .kd-menu-rtl {
631
+ direction: rtl;
632
+ }
633
+ .kd-menu-rtl .kd-menu-submenu {
634
+ direction: rtl;
635
+ }
636
+ .kd-menu-rtl .kd-menu-submenu .kd-menu-submenu-title .kd-menu-submenu-arrow {
637
+ margin-left: 0;
638
+ margin-right: auto;
639
+ }
@@ -124,13 +124,13 @@
124
124
 
125
125
  // dark
126
126
  .@{menu-dark-prefix-cls} {
127
-
128
127
  .@{submenu-prefix-cls}-sub {
129
128
  color: @menu-sub-color;
130
129
  background: @menu-sub-inline-color-background;
131
130
  }
132
131
 
133
- .@{submenu-prefix-cls}-sub-second, .@{submenu-prefix-cls}-sub-third {
132
+ .@{submenu-prefix-cls}-sub-second,
133
+ .@{submenu-prefix-cls}-sub-third {
134
134
  background: @menu-sub-color-background;
135
135
  }
136
136
 
@@ -140,29 +140,32 @@
140
140
  }
141
141
 
142
142
  &-active {
143
- .menu-dark-active()
143
+ .menu-dark-active();
144
144
  }
145
145
  }
146
146
 
147
- .@{menuitem-prefix-cls}-active, .@{submenu-prefix-cls}-active {
148
- .menu-dark-active()
147
+ .@{menuitem-prefix-cls}-active,
148
+ .@{submenu-prefix-cls}-active {
149
+ .menu-dark-active();
149
150
  }
150
151
 
151
- .@{menuitem-prefix-cls}-hover, .@{submenu-prefix-cls}-hover {
152
- .menu-dark-hover()
152
+ .@{menuitem-prefix-cls}-hover,
153
+ .@{submenu-prefix-cls}-hover {
154
+ .menu-dark-hover();
153
155
  }
154
156
  }
155
157
 
156
158
  .@{menu-inline-prefix-cls}.@{menu-dark-prefix-cls} {
157
- .@{menuitem-prefix-cls}-active, .@{submenu-prefix-cls}-active {
159
+ .@{menuitem-prefix-cls}-active,
160
+ .@{submenu-prefix-cls}-active {
158
161
  .@{submenu-prefix-cls}-title {
159
- .menu-dark-active-inline-title()
162
+ .menu-dark-active-inline-title();
160
163
  }
161
164
  }
162
165
 
163
166
  .@{submenu-prefix-cls}:not(.@{submenu-prefix-cls}-disabled):not(.@{submenu-prefix-cls}-active) {
164
167
  > .@{submenu-prefix-cls}-title:hover {
165
- .menu-dark-active-inline-title()
168
+ .menu-dark-active-inline-title();
166
169
  }
167
170
  }
168
171
  }
@@ -173,9 +176,10 @@
173
176
  }
174
177
 
175
178
  .@{menu-inline-prefix-cls}.@{menu-light-prefix-cls} {
176
- .@{menuitem-prefix-cls}-active, .@{submenu-prefix-cls}-active {
179
+ .@{menuitem-prefix-cls}-active,
180
+ .@{submenu-prefix-cls}-active {
177
181
  .@{submenu-prefix-cls}-title {
178
- .menu-light-active-inline-title()
182
+ .menu-light-active-inline-title();
179
183
  }
180
184
  }
181
185
  }
@@ -187,7 +191,7 @@
187
191
  }
188
192
 
189
193
  &.hidden {
190
- .menu-hidden()
194
+ .menu-hidden();
191
195
  }
192
196
 
193
197
  .@{submenu-prefix-cls} {
@@ -197,18 +201,18 @@
197
201
  color: @menu-sub-color;
198
202
  background: @menu-sub-inline-color-background;
199
203
  box-shadow: 0 3px 6px -4px rgba(0, 0, 0, 0.12), 0 6px 16px 0 rgba(0, 0, 0, 0.08),
200
- 0 9px 28px 8px rgba(0, 0, 0, 0.05);
204
+ 0 9px 28px 8px rgba(0, 0, 0, 0.05);
201
205
 
202
206
  .@{menuitem-prefix-cls} {
203
207
  &:not(.@{menuitem-prefix-cls}-disabled):not(.@{menuitem-prefix-cls}-active):hover,
204
208
  &-active {
205
- .menu-dark-hover()
209
+ .menu-dark-hover();
206
210
  }
207
211
  }
208
212
 
209
213
  &-second,
210
214
  &-third {
211
- animation: kdZoomTopLeftIn calc(@menu-motion-duration - 0.1s) cubic-bezier(0, .4, .4, 1) forwards;
215
+ animation: kdZoomTopLeftIn calc(@menu-motion-duration - 0.1s) cubic-bezier(0, 0.4, 0.4, 1) forwards;
212
216
  opacity: 1;
213
217
  visibility: visible;
214
218
  transition: opacity, visibility;
@@ -217,7 +221,7 @@
217
221
  }
218
222
 
219
223
  &-hide {
220
- .menu-hidden()
224
+ .menu-hidden();
221
225
  }
222
226
  }
223
227
  }
@@ -227,10 +231,17 @@
227
231
  }
228
232
  }
229
233
 
230
-
231
-
232
-
233
-
234
-
234
+ .@{menu-prefix-cls}-rtl {
235
+ direction: rtl;
236
+ .@{submenu-prefix-cls} {
237
+ direction: rtl;
238
+ .@{submenu-prefix-cls}-title {
239
+ .@{submenu-prefix-cls}-arrow {
240
+ margin-left: 0;
241
+ margin-right: auto;
242
+ }
243
+ }
244
+ }
245
+ }
235
246
 
236
247
 
@@ -36,7 +36,8 @@ var SubMenu = function SubMenu(props) {
36
36
  var _React$useContext = _react.default.useContext(_configProvider.ConfigContext),
37
37
  getPrefixCls = _React$useContext.getPrefixCls,
38
38
  pkgPrefixCls = _React$useContext.prefixCls,
39
- userDefaultProps = _React$useContext.compDefaultProps;
39
+ userDefaultProps = _React$useContext.compDefaultProps,
40
+ direction = _React$useContext.direction;
40
41
  var _a = (0, _utils.getCompProps)('MenuSubMenu', userDefaultProps, props),
41
42
  customPrefixcls = _a.prefixCls,
42
43
  theme = _a.theme,
@@ -233,9 +234,10 @@ var SubMenu = function SubMenu(props) {
233
234
  onMouseEnter: handleOnMouseEnter,
234
235
  onClick: handleOnClickSubMenu
235
236
  };
237
+ var isRtl = direction === 'rtl';
236
238
  var titleStyle = {
237
- paddingRight: "".concat(curPaddingRight, "px"),
238
- paddingLeft: "".concat(curPaddingLeft, "px")
239
+ paddingRight: isRtl ? "".concat(curPaddingLeft, "px") : "".concat(curPaddingRight, "px"),
240
+ paddingLeft: isRtl ? "".concat(curPaddingRight, "px") : "".concat(curPaddingLeft, "px")
239
241
  };
240
242
  var verticalView = (0, _usePopper.default)(_react.default.createElement("li", (0, _extends2.default)({
241
243
  className: (0, _classnames.default)(prefixCls, className, (_classNames2 = {}, (0, _defineProperty2.default)(_classNames2, "light", theme === 'light'), (0, _defineProperty2.default)(_classNames2, "".concat(prefixCls, "-collapsed"), collapsed), (0, _defineProperty2.default)(_classNames2, "".concat(prefixCls, "-disabled"), disabled), (0, _defineProperty2.default)(_classNames2, "".concat(prefixCls, "-hover"), !disabled && Array.isArray(openKeys) && (0, _includes.default)(openKeys).call(openKeys, keyValue)), (0, _defineProperty2.default)(_classNames2, "".concat(prefixCls, "-active"), Array.isArray(selectedKeyPath) && (0, _includes.default)(selectedKeyPath).call(selectedKeyPath, keyValue)), _classNames2)),
@@ -282,7 +284,7 @@ var SubMenu = function SubMenu(props) {
282
284
  });
283
285
  }))), {
284
286
  arrow: false,
285
- placement: 'rightTop',
287
+ placement: direction === 'rtl' ? 'leftTop' : 'rightTop',
286
288
  gap: 0,
287
289
  visible: isVertical && !disabled ? visible : false,
288
290
  disabled: isVertical ? undefined : true,
@@ -68,7 +68,8 @@ var InternalModal = function InternalModal(props, ref) {
68
68
  var _useContext = (0, _react.useContext)(_ConfigContext.default),
69
69
  getPrefixCls = _useContext.getPrefixCls,
70
70
  prefixCls = _useContext.prefixCls,
71
- userDefaultProps = _useContext.compDefaultProps;
71
+ userDefaultProps = _useContext.compDefaultProps,
72
+ direction = _useContext.direction;
72
73
  var modalProps = (0, _utils.getCompProps)('Modal', userDefaultProps, props);
73
74
  var body = modalProps.body,
74
75
  bodyClassName = modalProps.bodyClassName,
@@ -122,6 +123,7 @@ var InternalModal = function InternalModal(props, ref) {
122
123
  var wrapperRef = (0, _react.useRef)(null);
123
124
  var containerRef = ref || innerRef;
124
125
  var modalPrefixCls = getPrefixCls(prefixCls, 'modal', customPrefixcls);
126
+ var rtlCls = direction === 'rtl' ? "".concat(modalPrefixCls, "-rtl") : null;
125
127
  (0, _devwarning.default)(ModalTypes.indexOf(type) === -1, 'modal', "cannot found modal type '".concat(type, "'"));
126
128
  var modalContainer = typeof getContainer === 'function' ? getContainer() : getContainer;
127
129
  if (modalContainer !== false && !(modalContainer instanceof HTMLElement)) {
@@ -386,7 +388,7 @@ var InternalModal = function InternalModal(props, ref) {
386
388
  }
387
389
  };
388
390
  var isHidden = !destroyOnClose && !(isForceController ? visible : innerVisible);
389
- var modalClasses = (0, _classnames.default)(modalPrefixCls, className, (_classNames3 = {}, (0, _defineProperty2.default)(_classNames3, "".concat(modalPrefixCls, "-container"), true), (0, _defineProperty2.default)(_classNames3, "".concat(modalPrefixCls, "-container-ie"), _ieUtil.isIE), (0, _defineProperty2.default)(_classNames3, "".concat(modalPrefixCls, "-container-hidden"), isHidden), (0, _defineProperty2.default)(_classNames3, "".concat(modalPrefixCls, "-container-show"), !isHidden), _classNames3));
391
+ var modalClasses = (0, _classnames.default)(modalPrefixCls, rtlCls, className, (_classNames3 = {}, (0, _defineProperty2.default)(_classNames3, "".concat(modalPrefixCls, "-container"), true), (0, _defineProperty2.default)(_classNames3, "".concat(modalPrefixCls, "-container-ie"), _ieUtil.isIE), (0, _defineProperty2.default)(_classNames3, "".concat(modalPrefixCls, "-container-hidden"), isHidden), (0, _defineProperty2.default)(_classNames3, "".concat(modalPrefixCls, "-container-show"), !isHidden), _classNames3));
390
392
  var headerClass = (0, _classnames.default)("".concat(modalPrefixCls, "-header"), titleClassName);
391
393
  var container = _react.default.createElement("div", {
392
394
  className: (0, _classnames.default)((_classNames4 = {}, (0, _defineProperty2.default)(_classNames4, "".concat(modalPrefixCls, "-container-box"), true), (0, _defineProperty2.default)(_classNames4, "".concat(modalPrefixCls, "-has-container-box"), modalContainer && !overroll), (0, _defineProperty2.default)(_classNames4, "".concat(modalPrefixCls, "-showline"), showline), _classNames4)),
@@ -347,3 +347,10 @@
347
347
  .kd-modal-showline .kd-modal-footer {
348
348
  border-top: var(--kd-c-modal-sizing-border, 1px) solid var(--kd-c-modal-color-border, var(--kd-g-color-border-strong-2, #d9d9d9));
349
349
  }
350
+ .kd-modal-rtl {
351
+ direction: rtl;
352
+ }
353
+ .kd-modal-rtl .kd-modal-container-box .kd-modal-footer .kd-modal-cancel-node .kd-modal-margin-btn {
354
+ margin-left: var(--kd-c-modal-footer-button-spacing, 12px);
355
+ margin-right: 0;
356
+ }
@@ -226,3 +226,17 @@
226
226
  border-top: @modal-border-width solid @modal-border-color;
227
227
  }
228
228
  }
229
+
230
+ .@{modal-prefix-cls}-rtl {
231
+ direction: rtl;
232
+ .@{modal-prefix-cls}-container-box {
233
+ .@{modal-prefix-cls}-footer {
234
+ .@{modal-prefix-cls}-cancel-node {
235
+ .@{modal-prefix-cls}-margin-btn {
236
+ margin-left: @modal-footer-button-spacing;
237
+ margin-right: 0;
238
+ }
239
+ }
240
+ }
241
+ }
242
+ }
@@ -35,7 +35,8 @@ var Pagination = function Pagination(props) {
35
35
  getPrefixCls = _React$useContext.getPrefixCls,
36
36
  pkgPrefixCls = _React$useContext.prefixCls,
37
37
  userDefaultProps = _React$useContext.compDefaultProps,
38
- locale = _React$useContext.locale;
38
+ locale = _React$useContext.locale,
39
+ direction = _React$useContext.direction;
39
40
  var paginationLangMsg = locale.getCompLangMsg({
40
41
  componentName: 'Pagination'
41
42
  });
@@ -62,6 +63,7 @@ var Pagination = function Pagination(props) {
62
63
  customPrefixcls = _getCompProps.prefixCls;
63
64
  (0, _devwarning.default)(PageTypes.indexOf(pageType) === -1, 'Pagination', "cannot found pageType '".concat(pageType, "'"));
64
65
  var prefixCls = getPrefixCls(pkgPrefixCls, 'pagination', customPrefixcls);
66
+ var rtlCls = direction === 'rtl' ? "".concat(prefixCls, "-rtl") : null;
65
67
  var _React$useState = React.useState(pageSize || defaultPageSize),
66
68
  _React$useState2 = (0, _slicedToArray2.default)(_React$useState, 2),
67
69
  size = _React$useState2[0],
@@ -91,25 +93,25 @@ var Pagination = function Pagination(props) {
91
93
  setIsOpen = _React$useState8[1];
92
94
  var innerIcon = (0, _extends2.default)({
93
95
  first: React.createElement(_icon.default, {
94
- type: "first"
96
+ type: "".concat(direction === 'rtl' ? 'last' : 'first')
95
97
  }),
96
98
  last: React.createElement(_icon.default, {
97
- type: "last"
99
+ type: "".concat(direction === 'rtl' ? 'first' : 'last')
98
100
  }),
99
101
  prev: React.createElement(_icon.default, {
100
- type: "arrow-left"
102
+ type: "arrow-".concat(direction === 'rtl' ? 'right' : 'left')
101
103
  }),
102
104
  next: React.createElement(_icon.default, {
103
- type: "arrow-right"
105
+ type: "arrow-".concat(direction === 'rtl' ? 'left' : 'right')
104
106
  }),
105
107
  down: React.createElement(_icon.default, {
106
108
  type: "arrow-down"
107
109
  }),
108
110
  jumpPrev: React.createElement(_icon.default, {
109
- type: "double-arrow-left"
111
+ type: "double-arrow-".concat(direction === 'rtl' ? 'right' : 'left')
110
112
  }),
111
113
  jumpNext: React.createElement(_icon.default, {
112
- type: "double-arrow-right"
114
+ type: "double-arrow-".concat(direction === 'rtl' ? 'left' : 'right')
113
115
  })
114
116
  }, icons || {});
115
117
  var handleChangeSize = function handleChangeSize(key) {
@@ -207,7 +209,7 @@ var Pagination = function Pagination(props) {
207
209
  className: "".concat(prefixCls, "-total")
208
210
  }, mapTotalText[showTotal]);
209
211
  var normalPagination = React.createElement("div", {
210
- className: (0, _classnames.default)(prefixCls, className),
212
+ className: (0, _classnames.default)(prefixCls, rtlCls, className),
211
213
  style: style
212
214
  }, Total, showJumper && React.createElement("span", {
213
215
  className: "".concat(prefixCls, "-current")
@@ -242,7 +244,7 @@ var Pagination = function Pagination(props) {
242
244
  selectedKey: size,
243
245
  menu: sizeOptions,
244
246
  trigger: "click",
245
- placement: "bottomRight",
247
+ placement: direction === 'rtl' ? 'bottomRight' : 'bottomLeft',
246
248
  disabled: disabled,
247
249
  prefix: "".concat(prefixCls, "-dropdown"),
248
250
  popperStyle: {
@@ -260,7 +262,7 @@ var Pagination = function Pagination(props) {
260
262
  size: size
261
263
  })), innerIcon.down))));
262
264
  var simplePagination = React.createElement("div", {
263
- className: (0, _classnames.default)(prefixCls, 'simple', className),
265
+ className: (0, _classnames.default)(prefixCls, rtlCls, 'simple', className),
264
266
  style: style
265
267
  }, Total, React.createElement("ul", {
266
268
  className: (0, _classnames.default)("".concat(prefixCls, "-action"), {
@@ -290,7 +292,7 @@ var Pagination = function Pagination(props) {
290
292
  var lessPagination = null;
291
293
  if (pageType === 'less') {
292
294
  lessPagination = React.createElement("div", {
293
- className: (0, _classnames.default)(prefixCls, 'less', {
295
+ className: (0, _classnames.default)(prefixCls, rtlCls, 'less', {
294
296
  bordered: bordered,
295
297
  disabled: disabled
296
298
  }, className),
@@ -328,7 +330,7 @@ var Pagination = function Pagination(props) {
328
330
  page >= 5 && nicetyPages.unshift(1, '<<');
329
331
  }
330
332
  var nicetyPagination = React.createElement("div", {
331
- className: (0, _classnames.default)(prefixCls, 'nicety', {
333
+ className: (0, _classnames.default)(prefixCls, rtlCls, 'nicety', {
332
334
  bordered: bordered,
333
335
  disabled: disabled
334
336
  }, className),
@@ -385,7 +387,8 @@ var Pagination = function Pagination(props) {
385
387
  onItemClick: handleChangeSize,
386
388
  getPopupContainer: function getPopupContainer(triggerNode) {
387
389
  return triggerNode === null || triggerNode === void 0 ? void 0 : triggerNode.parentElement;
388
- }
390
+ },
391
+ placement: direction === 'rtl' ? 'bottomRight' : 'bottomLeft'
389
392
  }, dropdownProps, {
390
393
  onVisibleChange: dropdownVisibleChange
391
394
  }), React.createElement("button", {