mediacube-ui 0.1.146 → 0.1.147
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
### [0.1.147](https://github.com/MediaCubeCo/mcui/compare/v0.1.146...v0.1.147) (2023-09-28)
|
|
6
|
+
|
|
5
7
|
### [0.1.146](https://github.com/MediaCubeCo/mcui/compare/v0.1.145...v0.1.146) (2023-09-21)
|
|
6
8
|
|
|
7
9
|
### [0.1.145](https://github.com/MediaCubeCo/mcui/compare/v0.1.144...v0.1.145) (2023-09-19)
|
package/package.json
CHANGED
|
@@ -51,6 +51,7 @@
|
|
|
51
51
|
import McTitle from '../../McTitle/McTitle'
|
|
52
52
|
import McSvgIcon from '../../McSvgIcon/McSvgIcon'
|
|
53
53
|
import fieldErrors from '../../../mixins/fieldErrors'
|
|
54
|
+
import { LANGUAGES } from '../../../helpers/consts'
|
|
54
55
|
export default {
|
|
55
56
|
name: 'McFieldCheckbox',
|
|
56
57
|
components: { McTitle, McSvgIcon },
|
|
@@ -161,7 +162,7 @@ export default {
|
|
|
161
162
|
'mc-field-checkbox--disabled': this.disabled,
|
|
162
163
|
'mc-field-checkbox--empty': !this.mainText && !this.$slots.default,
|
|
163
164
|
[`mc-field-checkbox--size-${this.checkboxSize}`]: !!this.checkboxSize,
|
|
164
|
-
'mc-field-checkbox--rtl':
|
|
165
|
+
'mc-field-checkbox--rtl': LANGUAGES.rtl.includes(this.locale),
|
|
165
166
|
}
|
|
166
167
|
},
|
|
167
168
|
inputProps() {
|
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
<!-- @slot Слот заголовка -->
|
|
5
5
|
<slot name="header">
|
|
6
6
|
<mc-title v-if="hasTitle" :ellipsis="false" max-width="100%" weight="medium">{{
|
|
7
|
-
|
|
8
|
-
|
|
7
|
+
computedTitle
|
|
8
|
+
}}</mc-title>
|
|
9
9
|
</slot>
|
|
10
10
|
</div>
|
|
11
11
|
<div class="mc-field-select__main">
|
|
@@ -98,6 +98,7 @@ import McSvgIcon from '../../McSvgIcon/McSvgIcon'
|
|
|
98
98
|
import McPreview from '../../../patterns/McPreview/McPreview'
|
|
99
99
|
import fieldErrors from '../../../mixins/fieldErrors'
|
|
100
100
|
import equalFieldHeight from '../../../mixins/equalFieldHeight'
|
|
101
|
+
import { LANGUAGES } from '../../../helpers/consts'
|
|
101
102
|
export default {
|
|
102
103
|
name: 'McFieldSelect',
|
|
103
104
|
components: { McSvgIcon, McAvatar, McTitle, McTooltip, MultiSelect, McPreview },
|
|
@@ -301,6 +302,13 @@ export default {
|
|
|
301
302
|
type: Boolean,
|
|
302
303
|
default: false,
|
|
303
304
|
},
|
|
305
|
+
/**
|
|
306
|
+
* Для какого языка селект
|
|
307
|
+
*/
|
|
308
|
+
locale: {
|
|
309
|
+
type: String,
|
|
310
|
+
default: null,
|
|
311
|
+
},
|
|
304
312
|
},
|
|
305
313
|
data() {
|
|
306
314
|
return {
|
|
@@ -353,6 +361,7 @@ export default {
|
|
|
353
361
|
'mc-field-select--is-empty-options-list': this.isEmptyOptionsList,
|
|
354
362
|
'mc-field-select--with-preview': this.optionWithPreview,
|
|
355
363
|
'mc-field-select--max-height': this.maxHeight,
|
|
364
|
+
'mc-field-select--rtl': LANGUAGES.rtl.includes(this.locale),
|
|
356
365
|
}
|
|
357
366
|
},
|
|
358
367
|
computedTitle() {
|
|
@@ -587,6 +596,7 @@ $text-white: scale-color($color-white, $alpha: -10%);
|
|
|
587
596
|
border-radius: $radius-100 !important;
|
|
588
597
|
padding: 0 $space-500 0 $space-100;
|
|
589
598
|
overflow: hidden;
|
|
599
|
+
text-align: start;
|
|
590
600
|
&:hover {
|
|
591
601
|
border-color: $color-purple;
|
|
592
602
|
}
|
|
@@ -611,6 +621,7 @@ $text-white: scale-color($color-white, $alpha: -10%);
|
|
|
611
621
|
font-family: $font-family-main;
|
|
612
622
|
margin-top: $space-50;
|
|
613
623
|
margin-bottom: $space-50;
|
|
624
|
+
margin-right: unset;
|
|
614
625
|
background-color: $color-lighter-purple;
|
|
615
626
|
color: $color-black;
|
|
616
627
|
padding: $size-50 $size-50 $size-50 $size-100;
|
|
@@ -903,55 +914,67 @@ $text-white: scale-color($color-white, $alpha: -10%);
|
|
|
903
914
|
text-overflow: ellipsis;
|
|
904
915
|
white-space: nowrap;
|
|
905
916
|
}
|
|
906
|
-
}
|
|
907
|
-
html[dir='rtl'] {
|
|
908
|
-
.mc-field-select {
|
|
909
|
-
&__single-label {
|
|
910
|
-
@include child-indent-right(0);
|
|
911
|
-
@include child-indent-left-rtl($space-50);
|
|
912
|
-
}
|
|
913
|
-
&__label-text {
|
|
914
|
-
padding-left: 0;
|
|
915
|
-
padding-right: $space-50;
|
|
916
|
-
&--indent-left {
|
|
917
|
-
margin-left: 0;
|
|
918
|
-
margin-right: $space-300;
|
|
919
|
-
}
|
|
920
|
-
}
|
|
921
917
|
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
padding-right: $space-50;
|
|
926
|
-
}
|
|
918
|
+
&--rtl {
|
|
919
|
+
direction: rtl;
|
|
920
|
+
}
|
|
927
921
|
|
|
928
|
-
|
|
929
|
-
|
|
922
|
+
@at-root {
|
|
923
|
+
#{$block-name}--rtl,
|
|
924
|
+
html[dir='rtl'] #{$block-name} {
|
|
925
|
+
&__single-label {
|
|
926
|
+
@include child-indent-right(0);
|
|
927
|
+
@include child-indent-left-rtl($space-50);
|
|
930
928
|
}
|
|
931
|
-
|
|
932
|
-
&__input {
|
|
929
|
+
&__label-text {
|
|
933
930
|
padding-left: 0;
|
|
934
931
|
padding-right: $space-50;
|
|
932
|
+
&--indent-left {
|
|
933
|
+
margin-left: 0;
|
|
934
|
+
margin-right: $space-300;
|
|
935
|
+
}
|
|
935
936
|
}
|
|
936
|
-
|
|
937
|
-
@include child-indent-right(0);
|
|
938
|
-
@include child-indent-left-rtl($space-100);
|
|
939
|
-
}
|
|
940
|
-
&__tags {
|
|
941
|
-
padding: 0 $space-100 0 $space-500;
|
|
942
|
-
}
|
|
943
|
-
&__select {
|
|
944
|
-
right: unset;
|
|
945
|
-
left: 1px;
|
|
946
|
-
}
|
|
947
|
-
}
|
|
948
|
-
&--with-preview {
|
|
949
|
-
.mc-preview {
|
|
950
|
-
align-items: center;
|
|
951
|
-
}
|
|
937
|
+
|
|
952
938
|
.multiselect {
|
|
939
|
+
&__placeholder {
|
|
940
|
+
padding-left: 0;
|
|
941
|
+
padding-right: $space-50;
|
|
942
|
+
width: 100%;
|
|
943
|
+
}
|
|
944
|
+
|
|
945
|
+
&__single {
|
|
946
|
+
padding-right: 0;
|
|
947
|
+
}
|
|
948
|
+
|
|
949
|
+
&__input {
|
|
950
|
+
padding-left: 0;
|
|
951
|
+
padding-right: $space-50;
|
|
952
|
+
}
|
|
953
|
+
&__tags-wrap {
|
|
954
|
+
@include child-indent-right(0);
|
|
955
|
+
@include child-indent-left-rtl($space-100);
|
|
956
|
+
}
|
|
957
|
+
&__tag-icon {
|
|
958
|
+
margin-left: unset;
|
|
959
|
+
margin-right: 7px;
|
|
960
|
+
}
|
|
953
961
|
&__tags {
|
|
954
|
-
padding: $space-
|
|
962
|
+
padding: 0 $space-100 0 $space-500;
|
|
963
|
+
text-align: right;
|
|
964
|
+
}
|
|
965
|
+
&__select {
|
|
966
|
+
right: unset;
|
|
967
|
+
left: 1px;
|
|
968
|
+
}
|
|
969
|
+
}
|
|
970
|
+
&--with-preview {
|
|
971
|
+
.mc-preview {
|
|
972
|
+
align-items: center;
|
|
973
|
+
}
|
|
974
|
+
.multiselect {
|
|
975
|
+
&__tags {
|
|
976
|
+
padding: $space-200 $space-150;
|
|
977
|
+
}
|
|
955
978
|
}
|
|
956
979
|
}
|
|
957
980
|
}
|
|
@@ -123,6 +123,7 @@ import McSvgIcon from '../../McSvgIcon/McSvgIcon'
|
|
|
123
123
|
import fieldErrors from '../../../mixins/fieldErrors'
|
|
124
124
|
import McTooltip from '../../McTooltip/McTooltip'
|
|
125
125
|
import equalFieldHeight from '../../../mixins/equalFieldHeight'
|
|
126
|
+
import { LANGUAGES } from '../../../helpers/consts'
|
|
126
127
|
|
|
127
128
|
export default {
|
|
128
129
|
name: 'McFieldText',
|
|
@@ -376,7 +377,7 @@ export default {
|
|
|
376
377
|
'mc-field-text--textarea-autosize': this.isTextareaAutosize,
|
|
377
378
|
'mc-field-text--disabled': this.disabled,
|
|
378
379
|
'mc-field-text--copy': this.copy,
|
|
379
|
-
'mc-field-text--rtl':
|
|
380
|
+
'mc-field-text--rtl': LANGUAGES.rtl.includes(this.locale),
|
|
380
381
|
}
|
|
381
382
|
},
|
|
382
383
|
computedTitle() {
|