@broxus/react-uikit 0.6.8 → 0.8.0

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.
@@ -379,6 +379,16 @@
379
379
  }
380
380
  }
381
381
 
382
+ /* OnClick + Active */
383
+ .uk-button-text:active,
384
+ .uk-button-text.uk-active {
385
+ background-color: var(--button-text-active-background);
386
+ color: var(--button-text-active-color);
387
+ @if mixin-exists(hook-button-text-active) {
388
+ @include hook-button-text-active;
389
+ }
390
+ }
391
+
382
392
  /*
383
393
  * Link
384
394
  * 1. Reset
@@ -408,6 +418,15 @@
408
418
  text-decoration: none;
409
419
  }
410
420
 
421
+ /* OnClick + Active */
422
+ .uk-button-link:active,
423
+ .uk-button-link.uk-active {
424
+ background-color: var(--button-link-active-background);
425
+ color: var(--button-link-active-color);
426
+ @if mixin-exists(hook-button-link-active) {
427
+ @include hook-button-link-active;
428
+ }
429
+ }
411
430
 
412
431
  /* Ghost modifiers
413
432
  ========================================================================== */
@@ -2,6 +2,9 @@ import * as React from 'react';
2
2
  import { type ButtonProps } from '../../components/Button';
3
3
  import { type BreakpointsConfig, type TooltipOptions } from '../../types';
4
4
  export type ColorMode = 'light' | 'dark';
5
+ type PropsWithMouseHandler = {
6
+ onClick: React.HTMLAttributes<HTMLElement>['onClick'];
7
+ };
5
8
  export type ConfigContextConsumedProps = {
6
9
  breakpoints: Exclude<BreakpointsConfig<number>, 'default'>;
7
10
  buttonShape?: ButtonProps['shape'];
@@ -9,6 +12,7 @@ export type ConfigContextConsumedProps = {
9
12
  cardPrimaryColorMode?: ColorMode;
10
13
  cardSecondaryColorMode?: ColorMode;
11
14
  cardTertiaryColorMode?: ColorMode;
15
+ controlClearIcon?: React.ReactNode | ((props: PropsWithMouseHandler) => React.ReactElement);
12
16
  direction?: string;
13
17
  getPopupContainer?: (triggerNode?: HTMLElement) => HTMLElement;
14
18
  getRootPrefixCls: (prefix?: string, component?: string) => string;
@@ -20,6 +24,14 @@ export type ConfigContextConsumedProps = {
20
24
  sectionPrimaryColorMode?: ColorMode;
21
25
  sectionSecondaryColorMode?: ColorMode;
22
26
  sectionTertiaryColorMode?: ColorMode;
27
+ selectAddIcon?: React.ReactNode | ((props: PropsWithMouseHandler) => React.ReactElement);
28
+ selectArrowIcon?: React.ReactNode | ((props: {
29
+ isOpen: boolean;
30
+ } & PropsWithMouseHandler) => React.ReactElement);
31
+ selectClearIcon?: React.ReactNode | (() => React.ReactElement);
32
+ selectLoadingIcon?: React.ReactNode | (() => React.ReactElement);
33
+ selectNotFoundContent?: React.ReactNode | (() => React.ReactElement);
34
+ selectSearchIcon?: React.ReactNode | (() => React.ReactElement);
23
35
  tilePrimaryColorMode?: ColorMode;
24
36
  tileSecondaryColorMode?: ColorMode;
25
37
  tileTertiaryColorMode?: ColorMode;
@@ -28,3 +40,4 @@ export type ConfigContextProviderProps = React.PropsWithChildren<ConfigContextCo
28
40
  export declare const ConfigContext: React.Context<ConfigContextConsumedProps>;
29
41
  export declare function useConfig(): ConfigContextConsumedProps;
30
42
  export declare function ConfigContextProvider(props: Partial<ConfigContextProviderProps>): React.JSX.Element;
43
+ export {};
@@ -36,7 +36,7 @@ const Icon_1 = require("../../../components/Icon");
36
36
  require("../index.scss");
37
37
  exports.Input = React.forwardRef((props, ref) => {
38
38
  const config = (0, ConfigProvider_1.useConfig)();
39
- const { allowClear, inputRef, prefix, prefixCls = config.prefixCls, suffix, wrapperClasses, onClear, ...restProps } = (0, useInput_1.useInput)({
39
+ const { allowClear, htmlSize, inputRef, prefix, prefixCls = config.prefixCls, suffix, wrapperClasses, onClear, ...restProps } = (0, useInput_1.useInput)({
40
40
  type: 'text',
41
41
  ...props,
42
42
  });
@@ -48,6 +48,19 @@ exports.Input = React.forwardRef((props, ref) => {
48
48
  [`${prefixCls || config.prefixCls}-empty`]: !restProps.value,
49
49
  }),
50
50
  }, ['dir', 'size']);
51
+ const clearIcon = React.useMemo(() => {
52
+ if (typeof config.controlClearIcon === 'function') {
53
+ return config.controlClearIcon({
54
+ onClick: (event) => {
55
+ onClear?.(event);
56
+ },
57
+ });
58
+ }
59
+ if (React.isValidElement(config.controlClearIcon)) {
60
+ return config.controlClearIcon;
61
+ }
62
+ return (React.createElement(Icon_1.Icon, { key: "clearfix-icon", icon: "close", className: `${controlCls}-clear`, onClick: onClear }));
63
+ }, [config, controlCls, onClear]);
51
64
  React.useImperativeHandle(ref, () => ({
52
65
  blur() {
53
66
  inputRef.current?.blur();
@@ -62,8 +75,8 @@ exports.Input = React.forwardRef((props, ref) => {
62
75
  return (React.createElement("label", { className: wrapperClasses, htmlFor: restProps.id },
63
76
  prefix && (React.createElement("span", { key: "prefix", className: `${controlCls}-prefix` }, prefix)),
64
77
  React.createElement("span", { key: "input", className: `${controlCls}-input` },
65
- React.createElement("input", { ref: inputRef, ...inputProps, type: restProps.type })),
66
- allowClear && restProps.value && (React.createElement(Icon_1.Icon, { key: "clearfix-icon", icon: "close", className: `${controlCls}-clear`, onClick: onClear })),
78
+ React.createElement("input", { ref: inputRef, ...inputProps, size: htmlSize, type: restProps.type })),
79
+ allowClear && restProps.value && clearIcon,
67
80
  suffix && (React.createElement("span", { key: "suffix", className: `${controlCls}-suffix` }, suffix))));
68
81
  });
69
82
  if (process.env.NODE_ENV !== 'production') {
@@ -11,6 +11,7 @@ export interface InputRef {
11
11
  }
12
12
  export type OmittedNativeInput = Omit<React.InputHTMLAttributes<HTMLInputElement>, 'value' | 'defaultValue' | 'defaultChecked' | 'size' | 'prefix' | 'type' | 'max' | 'min'>;
13
13
  export interface InputProps<T extends ValueType = ValueType> extends OmittedNativeInput, ControlProps<T> {
14
+ htmlSize?: number | undefined;
14
15
  useInternalValueState?: boolean;
15
16
  onClear?(event: React.MouseEvent<HTMLElement>): void;
16
17
  }
@@ -39,7 +39,7 @@ const SECRET_COMBOBOX_MODE_DO_NOT_USE = 'SECRET_COMBOBOX_MODE_DO_NOT_USE';
39
39
  /* eslint-disable jsx-a11y/label-has-associated-control */
40
40
  function InternalSelect(props, ref) {
41
41
  const config = (0, ConfigProvider_1.useConfig)();
42
- const { className, listHeight = 256, listItemHeight = 24, prefixCls = config.prefixCls, showArrow = true, showSearch = false, onPressEnter, ...restProps } = props;
42
+ const { allowClear, className, listHeight = 256, listItemHeight = 24, prefixCls = config.prefixCls, showArrow = true, showSearch = false, onPressEnter, ...restProps } = props;
43
43
  const inputRef = React.useRef(null);
44
44
  const labelRef = React.useRef(null);
45
45
  const [focused, setFocused] = React.useState(false);
@@ -69,8 +69,8 @@ function InternalSelect(props, ref) {
69
69
  restProps.onDropdownVisibleChange?.(open);
70
70
  }, [restProps]);
71
71
  const onClickIcon = React.useCallback(() => {
72
- setInternalOpen(true);
73
- }, []);
72
+ setInternalOpen(!internalOpen);
73
+ }, [internalOpen]);
74
74
  React.useEffect(() => {
75
75
  setInternalOpen(restProps.defaultOpen || restProps.open || internalOpen);
76
76
  }, [restProps.open, restProps.defaultOpen, internalOpen]);
@@ -115,20 +115,48 @@ function InternalSelect(props, ref) {
115
115
  // Arrow or loading icon
116
116
  let suffixIcon;
117
117
  if (restProps.loading) {
118
- suffixIcon = React.createElement(Spinner_1.Spinner, { key: "spinner", ratio: 0.9 });
118
+ if (typeof config.selectLoadingIcon === 'function') {
119
+ suffixIcon = config.selectLoadingIcon();
120
+ }
121
+ else if (React.isValidElement(config.selectLoadingIcon)) {
122
+ suffixIcon = config.selectLoadingIcon;
123
+ }
124
+ else {
125
+ suffixIcon = React.createElement(Spinner_1.Spinner, { key: "spinner", ratio: 0.7 });
126
+ }
119
127
  }
120
128
  else if (showArrow) {
121
129
  const isMultiple = mode === 'multiple' || mode === 'tags';
122
130
  if (isMultiple) {
123
- suffixIcon = React.createElement(Icon_1.Icon, { key: "add_box", icon: "add_box", onClick: onClickIcon });
131
+ if (typeof config.selectAddIcon === 'function') {
132
+ suffixIcon = config.selectAddIcon({ onClick: onClickIcon });
133
+ }
134
+ else if (React.isValidElement(config.selectAddIcon)) {
135
+ suffixIcon = config.selectAddIcon;
136
+ }
137
+ else {
138
+ suffixIcon = React.createElement(Icon_1.Icon, { key: "add_box", icon: "add_box", onClick: onClickIcon });
139
+ }
124
140
  }
125
141
  else if (showSearch && internalOpen) {
126
- suffixIcon = React.createElement(Icon_1.Icon, { key: "manage_search", icon: "manage_search" });
142
+ if (typeof config.selectSearchIcon === 'function') {
143
+ suffixIcon = config.selectSearchIcon();
144
+ }
145
+ else if (React.isValidElement(config.selectSearchIcon)) {
146
+ suffixIcon = config.selectSearchIcon;
147
+ }
148
+ else {
149
+ suffixIcon = React.createElement(Icon_1.Icon, { key: "manage_search", icon: "manage_search" });
150
+ }
151
+ }
152
+ else if (typeof config.selectArrowIcon === 'function') {
153
+ suffixIcon = config.selectArrowIcon({ isOpen: internalOpen, onClick: onClickIcon });
154
+ }
155
+ else if (React.isValidElement(config.selectArrowIcon)) {
156
+ suffixIcon = config.selectArrowIcon;
127
157
  }
128
158
  else {
129
- suffixIcon = internalOpen
130
- ? React.createElement(Icon_1.Icon, { key: "expand_less", icon: "expand_less" })
131
- : React.createElement(Icon_1.Icon, { key: "expand_more", icon: "expand_more", onClick: onClickIcon });
159
+ suffixIcon = internalOpen ? (React.createElement(Icon_1.Icon, { key: "expand_less", icon: "expand_less" })) : (React.createElement(Icon_1.Icon, { key: "expand_more", icon: "expand_more", onClick: onClickIcon }));
132
160
  }
133
161
  }
134
162
  // Not found content
@@ -139,9 +167,22 @@ function InternalSelect(props, ref) {
139
167
  else if (mode === 'combobox') {
140
168
  mergedNotFound = null;
141
169
  }
170
+ if (typeof config.selectNotFoundContent === 'function') {
171
+ mergedNotFound = config.selectNotFoundContent();
172
+ }
173
+ else if (React.isValidElement(config.selectNotFoundContent)) {
174
+ mergedNotFound = config.selectNotFoundContent;
175
+ }
176
+ let clearIcon = React.createElement(Icon_1.Icon, { icon: "clear" });
177
+ if (typeof config.selectClearIcon === 'function') {
178
+ clearIcon = config.selectClearIcon();
179
+ }
180
+ else if (React.isValidElement(config.selectClearIcon)) {
181
+ clearIcon = config.selectClearIcon;
182
+ }
142
183
  return {
143
- allowClear: {
144
- clearIcon: React.createElement(Icon_1.Icon, { icon: "clear" }),
184
+ allowClear: (allowClear || allowClear === undefined) && {
185
+ clearIcon,
145
186
  },
146
187
  dropdownMatchSelectWidth: true,
147
188
  listHeight,
@@ -167,13 +208,14 @@ function InternalSelect(props, ref) {
167
208
  restProps,
168
209
  showArrow,
169
210
  mode,
211
+ config,
212
+ allowClear,
170
213
  listHeight,
171
214
  listItemHeight,
172
215
  internalOpen,
173
216
  rootCls,
174
217
  showSearch,
175
218
  prefixCls,
176
- config.prefixCls,
177
219
  onBlur,
178
220
  onDropdownVisibleChange,
179
221
  onFocus,
@@ -192,9 +234,9 @@ function InternalSelect(props, ref) {
192
234
  },
193
235
  }));
194
236
  return (React.createElement("label", { ref: labelRef, className: wrapperClasses, htmlFor: restProps.id },
195
- React.createElement(rc_select_1.default, { ref: inputRef, ...inputProps, dropdownAlign: {
237
+ React.createElement(rc_select_1.default, { ref: inputRef, dropdownAlign: {
196
238
  offset: [offsetY, 5],
197
- }, mode: mode })));
239
+ }, ...inputProps, mode: mode })));
198
240
  }
199
241
  exports.Select = React.forwardRef(InternalSelect);
200
242
  exports.Select.SECRET_COMBOBOX_MODE_DO_NOT_USE = SECRET_COMBOBOX_MODE_DO_NOT_USE;
@@ -219,6 +219,7 @@
219
219
  flex-wrap: wrap;
220
220
  grid-gap: var(--select-gutter);
221
221
  height: auto;
222
+ line-height: normal;
222
223
  padding: 0;
223
224
  width: 100%;
224
225
  }
@@ -347,24 +348,47 @@
347
348
  cursor: not-allowed;
348
349
  }
349
350
 
351
+ .uk-control-select:not(.uk-control-rtl) .uk-select-arrow,
352
+ .uk-control-select:not(.uk-control-rtl) .uk-select-clear {
353
+ right: 0;
354
+ }
355
+
356
+ /* Arrow */
350
357
  .uk-select-arrow {
351
358
  --icon-size: var(--select-arrow-icon-size);
352
- right: 0;
353
359
  @if mixin-exists(hook-select-arrow) {
354
360
  @include hook-select-arrow;
355
361
  }
356
362
  }
357
363
 
364
+ /* Clear */
358
365
  .uk-select-clear {
359
366
  @if mixin-exists(hook-select-clear) {
360
367
  @include hook-select-clear;
361
368
  }
362
369
  }
363
370
 
364
- .uk-select-arrow + .uk-select-clear {
371
+ .uk-control-select .uk-select-arrow + .uk-select-clear {
372
+ width: calc(var(--select-height) * 0.6777);
373
+ }
374
+
375
+ .uk-control-select:not(.uk-control-rtl) .uk-select-arrow + .uk-select-clear {
365
376
  right: var(--select-height);
366
377
  }
367
378
 
379
+ /* Selector */
380
+ .uk-control-select:not(.uk-control-rtl) .uk-select-allow-clear .uk-select-selector,
381
+ .uk-control-select:not(.uk-control-rtl) .uk-select-show-arrow .uk-select-selector {
382
+ padding-right: var(--select-height);
383
+ }
384
+
385
+ .uk-control-select:not(.uk-control-rtl) .uk-select-allow-clear.uk-select-show-arrow .uk-select-selector {
386
+ --arrow-width: var(--select-height);
387
+ --clear-width: calc(var(--select-height) * 0.6777);
388
+ padding-right: calc(var(--arrow-width) + var(--clear-width));
389
+ }
390
+
391
+
368
392
  /* Dropdown
369
393
  ========================================================================== */
370
394
 
@@ -558,8 +582,25 @@
558
582
  width: var(--select-small-height);
559
583
  }
560
584
 
585
+ // Clear
561
586
  .uk-control-select.uk-control-small .uk-select-arrow + .uk-select-clear {
562
- width: var(--select-small-height);
587
+ width: calc(var(--select-small-height) * 0.6777);
588
+ }
589
+
590
+ .uk-control-select.uk-control-small:not(.uk-control-rtl) .uk-select-arrow + .uk-select-clear {
591
+ right: var(--select-small-height);
592
+ }
593
+
594
+ // Selector
595
+ .uk-control-select.uk-control-small:not(.uk-control-rtl) .uk-select-allow-clear .uk-select-selector,
596
+ .uk-control-select.uk-control-small:not(.uk-control-rtl) .uk-select-show-arrow .uk-select-selector {
597
+ padding-right: var(--select-small-height);
598
+ }
599
+
600
+ .uk-control-select.uk-control-small:not(.uk-control-rtl) .uk-select-allow-clear.uk-select-show-arrow .uk-select-selector {
601
+ --arrow-width: var(--select-small-height);
602
+ --clear-width: calc(var(--select-small-height) * 0.6777);
603
+ padding-right: calc(var(--arrow-width) + var(--clear-width));
563
604
  }
564
605
 
565
606
  /* Medium */
@@ -576,8 +617,25 @@
576
617
  width: var(--select-medium-height);
577
618
  }
578
619
 
620
+ // Clear
579
621
  .uk-control-select.uk-control-medium .uk-select-arrow + .uk-select-clear {
580
- width: var(--select-medium-height);
622
+ width: calc(var(--select-medium-height) * 0.6777);
623
+ }
624
+
625
+ .uk-control-select.uk-control-medium:not(.uk-control-rtl) .uk-select-arrow + .uk-select-clear {
626
+ right: var(--select-medium-height);
627
+ }
628
+
629
+ // Selector
630
+ .uk-control-select.uk-control-medium:not(.uk-control-rtl) .uk-select-allow-clear .uk-select-selector,
631
+ .uk-control-select.uk-control-medium:not(.uk-control-rtl) .uk-select-show-arrow .uk-select-selector {
632
+ padding-right: var(--select-medium-height);
633
+ }
634
+
635
+ .uk-control-select.uk-control-medium:not(.uk-control-rtl) .uk-select-allow-clear.uk-select-show-arrow .uk-select-selector {
636
+ --arrow-width: var(--select-medium-height);
637
+ --clear-width: calc(var(--select-medium-height) * 0.6777);
638
+ padding-right: calc(var(--arrow-width) + var(--clear-width));
581
639
  }
582
640
 
583
641
  /* Large */
@@ -589,13 +647,30 @@
589
647
  padding: 0 var(--select-selector-large-padding-horizontal);
590
648
  }
591
649
 
592
- .uk-control-select.uk-control-large .uk-select-arrow,
650
+ .uk-control-select.uk-control-large .uk-select-arrow ,
593
651
  .uk-control-select.uk-control-large .uk-select-clear {
594
- width: var(--select-large-height);
652
+ width: calc(var(--select-large-height) * 0.8667);
595
653
  }
596
654
 
655
+ // Clear
597
656
  .uk-control-select.uk-control-large .uk-select-arrow + .uk-select-clear {
598
- width: var(--select-large-height);
657
+ width: calc(var(--select-large-height) * 0.6777);
658
+ }
659
+
660
+ .uk-control-select.uk-control-large:not(.uk-control-rtl) .uk-select-arrow + .uk-select-clear {
661
+ right: calc(var(--select-large-height) * 0.8667);
662
+ }
663
+
664
+ // Selector
665
+ .uk-control-select.uk-control-large:not(.uk-control-rtl) .uk-select-allow-clear .uk-select-selector,
666
+ .uk-control-select.uk-control-large:not(.uk-control-rtl) .uk-select-show-arrow .uk-select-selector {
667
+ padding-right: calc(var(--select-large-height) * 0.8667);
668
+ }
669
+
670
+ .uk-control-select.uk-control-large:not(.uk-control-rtl) .uk-select-allow-clear.uk-select-show-arrow .uk-select-selector {
671
+ --arrow-width: calc(var(--select-large-height) * 0.8667);
672
+ --clear-width: calc(var(--select-large-height) * 0.6777);
673
+ padding-right: calc(var(--arrow-width) + var(--clear-width));
599
674
  }
600
675
 
601
676
  /* Right to Left Direction
@@ -606,29 +681,74 @@
606
681
  direction: rtl;
607
682
  }
608
683
 
609
- .uk-control-select.uk-control-rtl .uk-select-arrow {
684
+ .uk-control-select.uk-control-rtl .uk-select-arrow,
685
+ .uk-control-select.uk-control-rtl .uk-select-clear {
610
686
  left: 0;
611
- right: unset;
612
687
  }
613
688
 
614
- .uk-control-select.uk-control-rtl .uk-select-clear {
689
+ .uk-control-select.uk-control-rtl .uk-select-arrow + .uk-select-clear {
615
690
  left: var(--select-height);
616
- right: unset;
617
691
  }
618
692
 
619
- .uk-control-select.uk-control-small.uk-control-rtl .uk-select-clear {
693
+ .uk-control-select.uk-control-rtl .uk-select-allow-clear .uk-select-selector,
694
+ .uk-control-select.uk-control-rtl .uk-select-show-arrow .uk-select-selector {
695
+ padding-left: var(--select-height);
696
+ }
697
+
698
+ .uk-control-select.uk-control-rtl .uk-select-allow-clear.uk-select-show-arrow .uk-select-selector {
699
+ --arrow-width: var(--select-height);
700
+ --clear-width: calc(var(--select-height) * 0.6777);
701
+ padding-left: calc(var(--arrow-width) + var(--clear-width));
702
+ }
703
+
704
+ /* Small */
705
+ .uk-control-select.uk-control-small.uk-control-rtl .uk-select-arrow + .uk-select-clear {
620
706
  left: var(--select-small-height);
621
707
  }
622
708
 
623
- .uk-control-select.uk-control-medium.uk-control-rtl .uk-select-clear {
709
+ .uk-control-select.uk-control-small.uk-control-rtl .uk-select-allow-clear .uk-select-selector,
710
+ .uk-control-select.uk-control-small.uk-control-rtl .uk-select-show-arrow .uk-select-selector {
711
+ padding-left: var(--select-small-height);
712
+ }
713
+
714
+ .uk-control-select.uk-control-small.uk-control-rtl .uk-select-allow-clear.uk-select-show-arrow .uk-select-selector {
715
+ --arrow-width: var(--select-small-height);
716
+ --clear-width: calc(var(--select-small-height) * 0.6777);
717
+ padding-left: calc(var(--arrow-width) + var(--clear-width));
718
+ }
719
+
720
+ /* Medium */
721
+ .uk-control-select.uk-control-medium.uk-control-rtl .uk-select-arrow .uk-select-clear {
624
722
  left: var(--select-medium-height);
625
723
  }
626
724
 
725
+ .uk-control-select.uk-control-medium.uk-control-rtl .uk-select-allow-clear .uk-select-selector,
726
+ .uk-control-select.uk-control-medium.uk-control-rtl .uk-select-show-arrow .uk-select-selector {
727
+ padding-left: var(--select-medium-height);
728
+ }
729
+
730
+ .uk-control-select.uk-control-medium.uk-control-rtl .uk-select-allow-clear.uk-select-show-arrow .uk-select-selector {
731
+ --arrow-width: var(--select-medium-height);
732
+ --clear-width: calc(var(--select-medium-height) * 0.6777);
733
+ padding-left: calc(var(--arrow-width) + var(--clear-width));
734
+ }
735
+
736
+ /* Large */
627
737
  .uk-control-select.uk-control-large.uk-control-rtl .uk-select-clear {
628
- left: var(--select-large-height);
738
+ left: calc(var(--select-large-height) * 0.8667);
739
+ }
740
+
741
+ .uk-control-select.uk-control-large.uk-control-rtl .uk-select-allow-clear .uk-select-selector,
742
+ .uk-control-select.uk-control-large.uk-control-rtl .uk-select-show-arrow .uk-select-selector {
743
+ padding-left: calc(var(--select-large-height) * 0.8667);
744
+ }
745
+
746
+ .uk-control-select.uk-control-large.uk-control-rtl .uk-select-allow-clear.uk-select-show-arrow .uk-select-selector {
747
+ --arrow-width: calc(var(--select-large-height) * 0.8667);
748
+ --clear-width: calc(var(--select-large-height) * 0.6777);
749
+ padding-left: calc(var(--arrow-width) + var(--clear-width));
629
750
  }
630
751
 
631
- // Multiple overwrites
632
752
  .uk-control-select.uk-control-rtl .uk-select-selection-item-remove {
633
753
  padding-left: var(--select-gutter);
634
754
  padding-right: unset;
@@ -145,7 +145,14 @@ function InternalSubNav(props) {
145
145
  // =============================== Render ===============================
146
146
  const popupId = domDataId ? `${domDataId}-dropdown` : undefined;
147
147
  // Title
148
- let titleNode = (React.createElement("a", { role: disabled ? undefined : 'menuitem', tabIndex: disabled ? undefined : -1, ref: elementRef, title: typeof title === 'string' ? title : undefined, "aria-controls": popupId, "aria-disabled": disabled, "aria-expanded": open, "aria-haspopup": true, "data-nav-id": overflowDisabled && domDataId ? null : domDataId, style: { ...directionStyle }, onClick: onInternalTitleClick, onFocus: onInternalFocus, ...activeProps }, title));
148
+ let titleNode = (React.createElement("a", { role: disabled ? undefined : 'menuitem', tabIndex: disabled ? undefined : -1, ref: elementRef, title: typeof title === 'string' ? title : undefined, "aria-controls": popupId, "aria-disabled": disabled, "aria-expanded": open, "aria-haspopup": true, "data-nav-id": overflowDisabled && domDataId ? null : domDataId, style: { ...directionStyle }, onClick: onInternalTitleClick, onFocus: onInternalFocus, ...activeProps },
149
+ React.createElement(React.Fragment, { key: "children" },
150
+ title,
151
+ typeof mergedExpandIcon === 'function' ? mergedExpandIcon({
152
+ disabled,
153
+ isOpen: open,
154
+ isSubNav: true,
155
+ }) : mergedExpandIcon)));
149
156
  // Cache mode if it changes to `inline` which do not have popup motion
150
157
  const triggerModeRef = React.useRef(mode);
151
158
  if (mode !== 'inline' && connectedPath.length > 1) {
@@ -920,7 +920,7 @@ $select-small-height: $control-small-h
920
920
  $select-medium-height: $control-medium-height !default;
921
921
  $select-large-height: $control-large-height !default;
922
922
  $select-arrow-icon-size: 24px !default;
923
- $select-gutter: 7px !default;
923
+ $select-gutter: 5px !default;
924
924
  $select-small-gutter: 5px !default;
925
925
  $select-medium-gutter: 15px !default;
926
926
  $select-large-gutter: 12px !default;