@kdcloudjs/kdesign 1.8.29 → 1.8.30

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.
@@ -1,5 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  import { LocaleConfigType, CompLangMsgParams, ComponentType } from '../locale';
3
+ export declare const DirectionTypes: ["ltr", "rtl"];
4
+ export declare type DirectionType = typeof DirectionTypes[number];
3
5
  interface IntlUniversal {
4
6
  getCompLangMsg: (compLangMsgParams: CompLangMsgParams, customGetLangMsg?: (componentName: string, labelName: string, params: any) => any) => any;
5
7
  getLangMsg: (componentName: ComponentType | string, labelName: string, params?: any) => string | React.ReactNode[];
@@ -10,6 +12,7 @@ export interface IConfigProps {
10
12
  prefixCls?: string;
11
13
  localeConfig?: LocaleConfigType;
12
14
  locale?: IntlUniversal;
15
+ direction?: DirectionType;
13
16
  }
14
17
  export interface IContextConfigProps {
15
18
  getPrefixCls?: (configPrefixCls?: string, suffixCls?: string, customizePrefixCls?: string) => string;
@@ -17,6 +20,7 @@ export interface IContextConfigProps {
17
20
  prefixCls?: string;
18
21
  localeConfig?: LocaleConfigType;
19
22
  locale: IntlUniversal;
23
+ direction?: DirectionType;
20
24
  }
21
25
  declare const ConfigContext: import("react").Context<IContextConfigProps>;
22
26
  export default ConfigContext;
@@ -1,4 +1,6 @@
1
1
  import { createContext } from 'react';
2
2
  import defaultConfig from './defaultConfig';
3
+ import { tuple } from '../_utils/type';
4
+ export var DirectionTypes = tuple('ltr', 'rtl');
3
5
  var ConfigContext = createContext(defaultConfig);
4
6
  export default ConfigContext;
@@ -6,5 +6,6 @@ declare const defaultConfig: {
6
6
  getLangMsg: (componentName: string, labelName: string, params?: any) => string | import("react").ReactNode[];
7
7
  getCompLangMsg: (compLangMsgParams: import("../locale").CompLangMsgParams, customGetLangMsg?: ((componentName: string, labelName: string, params: any) => any) | undefined, localeDate?: any) => any;
8
8
  };
9
+ direction: "ltr" | "rtl";
9
10
  };
10
11
  export default defaultConfig;
@@ -12,6 +12,7 @@ var defaultConfig = {
12
12
  locale: {
13
13
  getLangMsg: getLangMsg,
14
14
  getCompLangMsg: getCompLangMsg
15
- }
15
+ },
16
+ direction: 'ltr'
16
17
  };
17
18
  export default defaultConfig;
@@ -21,7 +21,8 @@ var Pagination = function Pagination(props) {
21
21
  getPrefixCls = _React$useContext.getPrefixCls,
22
22
  pkgPrefixCls = _React$useContext.prefixCls,
23
23
  userDefaultProps = _React$useContext.compDefaultProps,
24
- locale = _React$useContext.locale;
24
+ locale = _React$useContext.locale,
25
+ direction = _React$useContext.direction;
25
26
  var paginationLangMsg = locale.getCompLangMsg({
26
27
  componentName: 'Pagination'
27
28
  });
@@ -48,6 +49,7 @@ var Pagination = function Pagination(props) {
48
49
  customPrefixcls = _getCompProps.prefixCls;
49
50
  devWarning(PageTypes.indexOf(pageType) === -1, 'Pagination', "cannot found pageType '".concat(pageType, "'"));
50
51
  var prefixCls = getPrefixCls(pkgPrefixCls, 'pagination', customPrefixcls);
52
+ var rtlCls = direction === 'rtl' ? "".concat(prefixCls, "-rtl") : null;
51
53
  var _React$useState = React.useState(pageSize || defaultPageSize),
52
54
  _React$useState2 = _slicedToArray(_React$useState, 2),
53
55
  size = _React$useState2[0],
@@ -77,25 +79,25 @@ var Pagination = function Pagination(props) {
77
79
  setIsOpen = _React$useState8[1];
78
80
  var innerIcon = _extends({
79
81
  first: React.createElement(Icon, {
80
- type: "first"
82
+ type: "".concat(direction === 'rtl' ? 'last' : 'first')
81
83
  }),
82
84
  last: React.createElement(Icon, {
83
- type: "last"
85
+ type: "".concat(direction === 'rtl' ? 'first' : 'last')
84
86
  }),
85
87
  prev: React.createElement(Icon, {
86
- type: "arrow-left"
88
+ type: "arrow-".concat(direction === 'rtl' ? 'right' : 'left')
87
89
  }),
88
90
  next: React.createElement(Icon, {
89
- type: "arrow-right"
91
+ type: "arrow-".concat(direction === 'rtl' ? 'left' : 'right')
90
92
  }),
91
93
  down: React.createElement(Icon, {
92
94
  type: "arrow-down"
93
95
  }),
94
96
  jumpPrev: React.createElement(Icon, {
95
- type: "double-arrow-left"
97
+ type: "double-arrow-".concat(direction === 'rtl' ? 'right' : 'left')
96
98
  }),
97
99
  jumpNext: React.createElement(Icon, {
98
- type: "double-arrow-right"
100
+ type: "double-arrow-".concat(direction === 'rtl' ? 'left' : 'right')
99
101
  })
100
102
  }, icons || {});
101
103
  var handleChangeSize = function handleChangeSize(key) {
@@ -193,7 +195,7 @@ var Pagination = function Pagination(props) {
193
195
  className: "".concat(prefixCls, "-total")
194
196
  }, mapTotalText[showTotal]);
195
197
  var normalPagination = React.createElement("div", {
196
- className: classNames(prefixCls, className),
198
+ className: classNames(prefixCls, rtlCls, className),
197
199
  style: style
198
200
  }, Total, showJumper && React.createElement("span", {
199
201
  className: "".concat(prefixCls, "-current")
@@ -228,7 +230,7 @@ var Pagination = function Pagination(props) {
228
230
  selectedKey: size,
229
231
  menu: sizeOptions,
230
232
  trigger: "click",
231
- placement: "bottomRight",
233
+ placement: direction === 'rtl' ? 'bottomRight' : 'bottomLeft',
232
234
  disabled: disabled,
233
235
  prefix: "".concat(prefixCls, "-dropdown"),
234
236
  popperStyle: {
@@ -246,7 +248,7 @@ var Pagination = function Pagination(props) {
246
248
  size: size
247
249
  })), innerIcon.down))));
248
250
  var simplePagination = React.createElement("div", {
249
- className: classNames(prefixCls, 'simple', className),
251
+ className: classNames(prefixCls, rtlCls, 'simple', className),
250
252
  style: style
251
253
  }, Total, React.createElement("ul", {
252
254
  className: classNames("".concat(prefixCls, "-action"), {
@@ -276,7 +278,7 @@ var Pagination = function Pagination(props) {
276
278
  var lessPagination = null;
277
279
  if (pageType === 'less') {
278
280
  lessPagination = React.createElement("div", {
279
- className: classNames(prefixCls, 'less', {
281
+ className: classNames(prefixCls, rtlCls, 'less', {
280
282
  bordered: bordered,
281
283
  disabled: disabled
282
284
  }, className),
@@ -314,7 +316,7 @@ var Pagination = function Pagination(props) {
314
316
  page >= 5 && nicetyPages.unshift(1, '<<');
315
317
  }
316
318
  var nicetyPagination = React.createElement("div", {
317
- className: classNames(prefixCls, 'nicety', {
319
+ className: classNames(prefixCls, rtlCls, 'nicety', {
318
320
  bordered: bordered,
319
321
  disabled: disabled
320
322
  }, className),
@@ -371,7 +373,8 @@ var Pagination = function Pagination(props) {
371
373
  onItemClick: handleChangeSize,
372
374
  getPopupContainer: function getPopupContainer(triggerNode) {
373
375
  return triggerNode === null || triggerNode === void 0 ? void 0 : triggerNode.parentElement;
374
- }
376
+ },
377
+ placement: direction === 'rtl' ? 'bottomRight' : 'bottomLeft'
375
378
  }, dropdownProps, {
376
379
  onVisibleChange: dropdownVisibleChange
377
380
  }), React.createElement("button", {
@@ -815,3 +815,75 @@
815
815
  -webkit-transform: rotate(180deg);
816
816
  transform: rotate(180deg);
817
817
  }
818
+ .kd-pagination-rtl {
819
+ direction: rtl;
820
+ }
821
+ .kd-pagination-rtl .kd-pagination-total {
822
+ margin-left: 12px;
823
+ margin-right: 0;
824
+ }
825
+ .kd-pagination-rtl .kd-pagination-current {
826
+ margin-right: 0;
827
+ margin-left: 12px;
828
+ }
829
+ .kd-pagination-rtl .kd-pagination-action .kd-pagination-action-item.bordered {
830
+ margin-left: calc(2 * var(--kd-c-pagination-button-spacing, 4px));
831
+ margin-right: 0;
832
+ }
833
+ .kd-pagination-rtl .kd-pagination-action .kd-pagination-action-item.bordered:last-child {
834
+ margin-left: 0;
835
+ }
836
+ .kd-pagination-rtl .kd-pagination-selector {
837
+ margin-right: 20px;
838
+ margin-left: 0;
839
+ }
840
+ .kd-pagination-rtl .kd-pagination-selector .kd-pagination-selector-size i {
841
+ margin-left: 0;
842
+ margin-right: 4px;
843
+ }
844
+ .kd-pagination-rtl.simple .kd-pagination-action-item .kd-pagination-current {
845
+ margin-right: 0;
846
+ margin-left: 2px;
847
+ }
848
+ .kd-pagination-rtl.simple .kd-pagination-action-item .kd-pagination-total {
849
+ margin-left: 0;
850
+ margin-right: 2px;
851
+ }
852
+ .kd-pagination-rtl.less .kd-pagination-pages-item {
853
+ margin-left: var(--kd-c-pagination-button-spacing, 4px);
854
+ margin-right: 0;
855
+ }
856
+ .kd-pagination-rtl.less .kd-pagination-pages-item:last-child {
857
+ margin-left: 0;
858
+ }
859
+ .kd-pagination-rtl.nicety .kd-pagination-pages-item {
860
+ margin-left: var(--kd-c-pagination-button-spacing, 4px);
861
+ margin-right: 0;
862
+ }
863
+ .kd-pagination-rtl.nicety .kd-pagination-pages-item:last-child {
864
+ margin-left: 0;
865
+ }
866
+ .kd-pagination-rtl.nicety .kd-pagination-jumper {
867
+ margin-right: var(--kd-c-pagination-button-spacing, 4px);
868
+ margin-left: 0;
869
+ }
870
+ .kd-pagination-rtl.nicety .kd-pagination-jumper .kd-pagination-jumper-button {
871
+ margin-right: var(--kd-c-pagination-button-spacing, 4px);
872
+ margin-left: 0;
873
+ }
874
+ .kd-pagination-rtl.nicety .kd-pagination-options {
875
+ margin-right: 22px;
876
+ margin-left: 0;
877
+ }
878
+ .kd-pagination-rtl.nicety .kd-pagination-options .kd-pagination-options-size {
879
+ margin-right: 0;
880
+ margin-left: 8px;
881
+ padding: 0 4px 0 24px;
882
+ }
883
+ .kd-pagination-rtl.nicety .kd-pagination-options .kd-pagination-options-size i {
884
+ left: 5px;
885
+ right: auto;
886
+ }
887
+ .kd-pagination-rtl.nicety .kd-pagination-options .kd-dropdown-menu-item > span {
888
+ text-align: right;
889
+ }
@@ -617,3 +617,102 @@
617
617
  }
618
618
  }
619
619
  }
620
+
621
+ .@{pagination-prefix-cls}-rtl {
622
+ direction: rtl;
623
+ .@{pagination-prefix-cls}-total {
624
+ margin-left: 12px;
625
+ margin-right: 0;
626
+ }
627
+ .@{pagination-prefix-cls}-current {
628
+ margin-right: 0;
629
+ margin-left: 12px;
630
+ }
631
+ .@{pagination-action-prefix-cls} {
632
+ .@{pagination-action-prefix-cls}-item {
633
+ &.bordered {
634
+ margin-left: calc(2 * @pagination-button-spacing);
635
+ margin-right: 0;
636
+ &:last-child {
637
+ margin-left: 0;
638
+ }
639
+ }
640
+ }
641
+ }
642
+ .@{pagination-selector-prefix-cls} {
643
+ margin-right: 20px;
644
+ margin-left: 0;
645
+ .@{pagination-selector-prefix-cls}-size {
646
+ i {
647
+ margin-left: 0;
648
+ margin-right: 4px;
649
+ }
650
+ }
651
+ }
652
+ &.simple {
653
+ .@{pagination-prefix-cls}-action {
654
+ &-item {
655
+ .@{pagination-prefix-cls}-current {
656
+ margin-right: 0;
657
+ margin-left: 2px;
658
+ }
659
+ .@{pagination-prefix-cls}-total {
660
+ margin-left: 0;
661
+ margin-right: 2px;
662
+ }
663
+ }
664
+ }
665
+ }
666
+ &.less {
667
+ .@{pagination-pages-prefix-cls} {
668
+ &-item {
669
+ margin-left: @pagination-button-spacing;
670
+ margin-right: 0;
671
+ &:last-child {
672
+ margin-left: 0;
673
+ }
674
+ }
675
+ }
676
+ }
677
+ &.nicety {
678
+ .@{pagination-pages-prefix-cls} {
679
+ &-item {
680
+ margin-left: @pagination-button-spacing;
681
+ margin-right: 0;
682
+ &:last-child {
683
+ margin-left: 0;
684
+ }
685
+ }
686
+ }
687
+ .@{pagination-jumper-prefix-cls} {
688
+ margin-right: @pagination-button-spacing;
689
+ margin-left: 0;
690
+ .@{pagination-jumper-prefix-cls}-button {
691
+ margin-right: @pagination-button-spacing;
692
+ margin-left: 0;
693
+ }
694
+ }
695
+ .@{pagination-options-prefix-cls} {
696
+ margin-right: 22px;
697
+ margin-left: 0;
698
+ .@{pagination-options-prefix-cls}-size {
699
+ margin-right: 0;
700
+ margin-left: 8px;
701
+ padding: 0 4px 0 24px;
702
+ i {
703
+ left: 5px;
704
+ right: auto;
705
+ }
706
+ }
707
+ .@{kd-prefix}-dropdown {
708
+ &-menu {
709
+ &-item {
710
+ & > span {
711
+ text-align: right;
712
+ }
713
+ }
714
+ }
715
+ }
716
+ }
717
+ }
718
+ }
@@ -1,5 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  import { LocaleConfigType, CompLangMsgParams, ComponentType } from '../locale';
3
+ export declare const DirectionTypes: ["ltr", "rtl"];
4
+ export declare type DirectionType = typeof DirectionTypes[number];
3
5
  interface IntlUniversal {
4
6
  getCompLangMsg: (compLangMsgParams: CompLangMsgParams, customGetLangMsg?: (componentName: string, labelName: string, params: any) => any) => any;
5
7
  getLangMsg: (componentName: ComponentType | string, labelName: string, params?: any) => string | React.ReactNode[];
@@ -10,6 +12,7 @@ export interface IConfigProps {
10
12
  prefixCls?: string;
11
13
  localeConfig?: LocaleConfigType;
12
14
  locale?: IntlUniversal;
15
+ direction?: DirectionType;
13
16
  }
14
17
  export interface IContextConfigProps {
15
18
  getPrefixCls?: (configPrefixCls?: string, suffixCls?: string, customizePrefixCls?: string) => string;
@@ -17,6 +20,7 @@ export interface IContextConfigProps {
17
20
  prefixCls?: string;
18
21
  localeConfig?: LocaleConfigType;
19
22
  locale: IntlUniversal;
23
+ direction?: DirectionType;
20
24
  }
21
25
  declare const ConfigContext: import("react").Context<IContextConfigProps>;
22
26
  export default ConfigContext;
@@ -4,9 +4,12 @@ var _interopRequireDefault = require("@babel/runtime-corejs3/helpers/interopRequ
4
4
  Object.defineProperty(exports, "__esModule", {
5
5
  value: true
6
6
  });
7
- exports.default = void 0;
7
+ exports.default = exports.DirectionTypes = void 0;
8
8
  var _react = require("react");
9
9
  var _defaultConfig = _interopRequireDefault(require("./defaultConfig"));
10
+ var _type = require("../_utils/type");
11
+ var DirectionTypes = (0, _type.tuple)('ltr', 'rtl');
12
+ exports.DirectionTypes = DirectionTypes;
10
13
  var ConfigContext = (0, _react.createContext)(_defaultConfig.default);
11
14
  var _default = ConfigContext;
12
15
  exports.default = _default;
@@ -6,5 +6,6 @@ declare const defaultConfig: {
6
6
  getLangMsg: (componentName: string, labelName: string, params?: any) => string | import("react").ReactNode[];
7
7
  getCompLangMsg: (compLangMsgParams: import("../locale").CompLangMsgParams, customGetLangMsg?: ((componentName: string, labelName: string, params: any) => any) | undefined, localeDate?: any) => any;
8
8
  };
9
+ direction: "ltr" | "rtl";
9
10
  };
10
11
  export default defaultConfig;
@@ -19,7 +19,8 @@ var defaultConfig = {
19
19
  locale: {
20
20
  getLangMsg: _locale.getLangMsg,
21
21
  getCompLangMsg: _locale.getCompLangMsg
22
- }
22
+ },
23
+ direction: 'ltr'
23
24
  };
24
25
  var _default = defaultConfig;
25
26
  exports.default = _default;
@@ -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", {
@@ -815,3 +815,75 @@
815
815
  -webkit-transform: rotate(180deg);
816
816
  transform: rotate(180deg);
817
817
  }
818
+ .kd-pagination-rtl {
819
+ direction: rtl;
820
+ }
821
+ .kd-pagination-rtl .kd-pagination-total {
822
+ margin-left: 12px;
823
+ margin-right: 0;
824
+ }
825
+ .kd-pagination-rtl .kd-pagination-current {
826
+ margin-right: 0;
827
+ margin-left: 12px;
828
+ }
829
+ .kd-pagination-rtl .kd-pagination-action .kd-pagination-action-item.bordered {
830
+ margin-left: calc(2 * var(--kd-c-pagination-button-spacing, 4px));
831
+ margin-right: 0;
832
+ }
833
+ .kd-pagination-rtl .kd-pagination-action .kd-pagination-action-item.bordered:last-child {
834
+ margin-left: 0;
835
+ }
836
+ .kd-pagination-rtl .kd-pagination-selector {
837
+ margin-right: 20px;
838
+ margin-left: 0;
839
+ }
840
+ .kd-pagination-rtl .kd-pagination-selector .kd-pagination-selector-size i {
841
+ margin-left: 0;
842
+ margin-right: 4px;
843
+ }
844
+ .kd-pagination-rtl.simple .kd-pagination-action-item .kd-pagination-current {
845
+ margin-right: 0;
846
+ margin-left: 2px;
847
+ }
848
+ .kd-pagination-rtl.simple .kd-pagination-action-item .kd-pagination-total {
849
+ margin-left: 0;
850
+ margin-right: 2px;
851
+ }
852
+ .kd-pagination-rtl.less .kd-pagination-pages-item {
853
+ margin-left: var(--kd-c-pagination-button-spacing, 4px);
854
+ margin-right: 0;
855
+ }
856
+ .kd-pagination-rtl.less .kd-pagination-pages-item:last-child {
857
+ margin-left: 0;
858
+ }
859
+ .kd-pagination-rtl.nicety .kd-pagination-pages-item {
860
+ margin-left: var(--kd-c-pagination-button-spacing, 4px);
861
+ margin-right: 0;
862
+ }
863
+ .kd-pagination-rtl.nicety .kd-pagination-pages-item:last-child {
864
+ margin-left: 0;
865
+ }
866
+ .kd-pagination-rtl.nicety .kd-pagination-jumper {
867
+ margin-right: var(--kd-c-pagination-button-spacing, 4px);
868
+ margin-left: 0;
869
+ }
870
+ .kd-pagination-rtl.nicety .kd-pagination-jumper .kd-pagination-jumper-button {
871
+ margin-right: var(--kd-c-pagination-button-spacing, 4px);
872
+ margin-left: 0;
873
+ }
874
+ .kd-pagination-rtl.nicety .kd-pagination-options {
875
+ margin-right: 22px;
876
+ margin-left: 0;
877
+ }
878
+ .kd-pagination-rtl.nicety .kd-pagination-options .kd-pagination-options-size {
879
+ margin-right: 0;
880
+ margin-left: 8px;
881
+ padding: 0 4px 0 24px;
882
+ }
883
+ .kd-pagination-rtl.nicety .kd-pagination-options .kd-pagination-options-size i {
884
+ left: 5px;
885
+ right: auto;
886
+ }
887
+ .kd-pagination-rtl.nicety .kd-pagination-options .kd-dropdown-menu-item > span {
888
+ text-align: right;
889
+ }
@@ -617,3 +617,102 @@
617
617
  }
618
618
  }
619
619
  }
620
+
621
+ .@{pagination-prefix-cls}-rtl {
622
+ direction: rtl;
623
+ .@{pagination-prefix-cls}-total {
624
+ margin-left: 12px;
625
+ margin-right: 0;
626
+ }
627
+ .@{pagination-prefix-cls}-current {
628
+ margin-right: 0;
629
+ margin-left: 12px;
630
+ }
631
+ .@{pagination-action-prefix-cls} {
632
+ .@{pagination-action-prefix-cls}-item {
633
+ &.bordered {
634
+ margin-left: calc(2 * @pagination-button-spacing);
635
+ margin-right: 0;
636
+ &:last-child {
637
+ margin-left: 0;
638
+ }
639
+ }
640
+ }
641
+ }
642
+ .@{pagination-selector-prefix-cls} {
643
+ margin-right: 20px;
644
+ margin-left: 0;
645
+ .@{pagination-selector-prefix-cls}-size {
646
+ i {
647
+ margin-left: 0;
648
+ margin-right: 4px;
649
+ }
650
+ }
651
+ }
652
+ &.simple {
653
+ .@{pagination-prefix-cls}-action {
654
+ &-item {
655
+ .@{pagination-prefix-cls}-current {
656
+ margin-right: 0;
657
+ margin-left: 2px;
658
+ }
659
+ .@{pagination-prefix-cls}-total {
660
+ margin-left: 0;
661
+ margin-right: 2px;
662
+ }
663
+ }
664
+ }
665
+ }
666
+ &.less {
667
+ .@{pagination-pages-prefix-cls} {
668
+ &-item {
669
+ margin-left: @pagination-button-spacing;
670
+ margin-right: 0;
671
+ &:last-child {
672
+ margin-left: 0;
673
+ }
674
+ }
675
+ }
676
+ }
677
+ &.nicety {
678
+ .@{pagination-pages-prefix-cls} {
679
+ &-item {
680
+ margin-left: @pagination-button-spacing;
681
+ margin-right: 0;
682
+ &:last-child {
683
+ margin-left: 0;
684
+ }
685
+ }
686
+ }
687
+ .@{pagination-jumper-prefix-cls} {
688
+ margin-right: @pagination-button-spacing;
689
+ margin-left: 0;
690
+ .@{pagination-jumper-prefix-cls}-button {
691
+ margin-right: @pagination-button-spacing;
692
+ margin-left: 0;
693
+ }
694
+ }
695
+ .@{pagination-options-prefix-cls} {
696
+ margin-right: 22px;
697
+ margin-left: 0;
698
+ .@{pagination-options-prefix-cls}-size {
699
+ margin-right: 0;
700
+ margin-left: 8px;
701
+ padding: 0 4px 0 24px;
702
+ i {
703
+ left: 5px;
704
+ right: auto;
705
+ }
706
+ }
707
+ .@{kd-prefix}-dropdown {
708
+ &-menu {
709
+ &-item {
710
+ & > span {
711
+ text-align: right;
712
+ }
713
+ }
714
+ }
715
+ }
716
+ }
717
+ }
718
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kdcloudjs/kdesign",
3
- "version": "1.8.29",
3
+ "version": "1.8.30",
4
4
  "description": "KDesign 金蝶前端react 组件库",
5
5
  "title": "kdesign",
6
6
  "keywords": [