@ldmjs/ui 2.0.0-beta.2 → 2.0.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.
Files changed (52) hide show
  1. package/dist/components/ld-avatar.js +1 -1
  2. package/dist/components/ld-badge.js +1 -1
  3. package/dist/components/ld-breadcrumbs.js +1 -1
  4. package/dist/components/ld-button.js +1 -1
  5. package/dist/components/ld-calendar.js +1 -1
  6. package/dist/components/ld-checkbox.js +1 -1
  7. package/dist/components/ld-chip.js +1 -1
  8. package/dist/components/ld-combobox.js +1 -1
  9. package/dist/components/ld-data-iterator.js +1 -1
  10. package/dist/components/ld-datepicker.js +1 -1
  11. package/dist/components/ld-dialog.js +1 -1
  12. package/dist/components/ld-edit-list-box.js +1 -1
  13. package/dist/components/ld-edit-masked-text.js +1 -1
  14. package/dist/components/ld-edit-text.js +1 -1
  15. package/dist/components/ld-expansion-panel.js +1 -1
  16. package/dist/components/ld-expansion-panels.js +1 -1
  17. package/dist/components/ld-icon.js +1 -1
  18. package/dist/components/ld-loader.js +1 -1
  19. package/dist/components/ld-page-toolbar.js +1 -1
  20. package/dist/components/ld-pager.js +1 -1
  21. package/dist/components/ld-progress.js +1 -1
  22. package/dist/components/ld-radiobutton.js +1 -1
  23. package/dist/components/ld-radiogroup.js +1 -1
  24. package/dist/components/ld-select-list-box.js +1 -1
  25. package/dist/components/ld-select.js +1 -1
  26. package/dist/components/ld-slider.js +1 -1
  27. package/dist/components/ld-splitter.js +1 -1
  28. package/dist/components/ld-step.js +1 -1
  29. package/dist/components/ld-switch.js +1 -1
  30. package/dist/components/ld-tab.js +1 -1
  31. package/dist/components/ld-tabs.js +1 -1
  32. package/dist/components/ld-text-markup.js +1 -1
  33. package/dist/components/ld-text-viewer.js +1 -1
  34. package/dist/components/ld-textarea.js +1 -1
  35. package/dist/components/ld-timepicker.js +1 -1
  36. package/dist/components/ld-toggle-buttons.js +1 -1
  37. package/dist/components/ld-uploader.js +1 -1
  38. package/dist/index.js +1 -1
  39. package/dist/lib/imask.js +1 -1
  40. package/dist/lib/runtime-template.js +1 -1
  41. package/dist/lib/toastification.js +1 -1
  42. package/dist/scss/_badge.scss +121 -45
  43. package/dist/scss/_buttons.scss +48 -3
  44. package/dist/scss/_calendar.scss +1 -3
  45. package/dist/scss/_chip.scss +126 -23
  46. package/dist/scss/_inputs.scss +122 -80
  47. package/dist/scss/_tabs.scss +113 -117
  48. package/dist/scss/index.scss +0 -1
  49. package/dist/scss/utils.scss +6 -0
  50. package/dist/types/options.d.ts +1 -1
  51. package/dist/utils/validators.js +1 -1
  52. package/package.json +5 -4
@@ -51,10 +51,13 @@ $input-border-color-hover: var(--grey);
51
51
  $input-disabled-color: var(--grey-l-2);
52
52
  $input-disabled-background-color: var(--grey-l-6);
53
53
 
54
+ $input-border-color-readonly: var(--grey-l-6);
55
+ $input-readonly-color: var(--grey-d-3);
56
+
54
57
  $colors: (
55
58
  "grey": ("default": $input-border-color-default, "hover": $input-border-color-hover),
56
- "success": ("default": var(--success-d-1), "hover": var(--success-d-1)),
57
- "error": ("default": var(--error), "hover": var(--error)),
59
+ "success": ("default": var(--success-d-1), "hover": var(--success-d-2)),
60
+ "error": ("default": var(--error), "hover": var(--error-d-1)),
58
61
  );
59
62
 
60
63
  :root {
@@ -67,6 +70,46 @@ $colors: (
67
70
  --input-disabled-background-color: #{$input-disabled-background-color};
68
71
  }
69
72
 
73
+ @mixin inputlabel($parent, $size) {
74
+ $label-on-top: utils.getSelector($parent, '--label-on-top');
75
+ @include utils.not-class(utils.getSelector($parent, '--label-on-top')) {
76
+ .ld-label {
77
+ height: $size;
78
+ }
79
+ }
80
+ &#{utils.getSelector($parent, '--label-on-top')} {
81
+ .ld-label {
82
+ margin-bottom: 4px;
83
+ }
84
+ }
85
+
86
+ .ld-label {
87
+ font-size: var(--text-body-s);
88
+ &-content {
89
+ color: var(--grey-d-1);
90
+ }
91
+ }
92
+ }
93
+
94
+ @mixin inputdetails() {
95
+ .v-input__details {
96
+ position: relative;
97
+ padding: 0 !important;
98
+ margin: 6px 0 0 0 !important;
99
+ z-index: 1;
100
+ height: 20px;
101
+ min-height: 20px;
102
+ align-items: center;
103
+
104
+ .v-messages {
105
+ color: var(--grey-d-1);
106
+ font-family: var(--regular);
107
+ font-size: var(--font-size);
108
+ line-height: calc(var(--font-size) + 6px);
109
+ }
110
+ }
111
+ }
112
+
70
113
  @mixin inputsize() {
71
114
  $parent: utils.getParent(&);
72
115
 
@@ -100,19 +143,9 @@ $colors: (
100
143
  }
101
144
  }
102
145
 
103
- .ld-label {
104
- height: $size;
105
- &-content {
106
- font-size: $font;
107
- }
108
- }
146
+ @include inputlabel($parent, $size);
109
147
 
110
- .v-input__details {
111
- .v-messages {
112
- font-size: calc($font - 2px);
113
- line-height: calc($font - 2px + 6px);
114
- }
115
- }
148
+ @include inputdetails();
116
149
 
117
150
  #{utils.getSelector($parent, '-help')} {
118
151
  display: flex;
@@ -248,29 +281,37 @@ $colors: (
248
281
  }
249
282
  }
250
283
 
251
- &:hover {
252
- .v-field.v-field--variant-outlined {
253
- @include vfieldoutline($hover);
284
+ &:not(.v-input--readonly) {
285
+ &:hover {
286
+ .v-field.v-field--variant-outlined {
287
+ @include vfieldoutline($hover);
288
+ }
289
+
290
+ .v-input__append {
291
+ &:after {
292
+ border-color: $hover;
293
+ border-width: 1px;
294
+ }
295
+ }
254
296
  }
255
297
 
256
- .v-input__append {
257
- &:after {
258
- border-color: $hover;
259
- border-width: 1px;
298
+ &.v-input--focused {
299
+ .v-field.v-field--variant-outlined {
300
+ @include vfieldoutline(var(--focus));
301
+ }
302
+
303
+ .v-input__append {
304
+ &:after {
305
+ border-color: var(--focus);
306
+ border-width: 2px;
307
+ }
260
308
  }
261
309
  }
262
310
  }
263
311
 
264
- &.v-input--focused {
312
+ &.v-input--readonly {
265
313
  .v-field.v-field--variant-outlined {
266
- @include vfieldoutline(var(--focus));
267
- }
268
-
269
- .v-input__append {
270
- &:after {
271
- border-color: var(--focus);
272
- border-width: 2px;
273
- }
314
+ @include vfieldoutline($input-border-color-readonly);
274
315
  }
275
316
  }
276
317
  }
@@ -302,22 +343,6 @@ $colors: (
302
343
  }
303
344
  }
304
345
 
305
- @mixin inputdetails() {
306
- .v-input__details {
307
- position: relative;
308
- padding: 0 !important;
309
- margin: 6px 0 0 0 !important;
310
- z-index: 1;
311
- height: 20px;
312
- min-height: 20px;
313
- align-items: center;
314
-
315
- .v-messages {
316
- color: var(--grey-d-1);
317
- }
318
- }
319
- }
320
-
321
346
  @mixin inputloader() {
322
347
  $parent: utils.getParent(&);
323
348
  $selector: utils.getSelector($parent, '-loader');
@@ -448,9 +473,17 @@ body {
448
473
  }
449
474
 
450
475
  .v-input {
451
- .v-input__details {
452
- .v-messages {
453
- font-family: var(--regular);
476
+ &.v-input--readonly {
477
+ &.v-input--focused {
478
+ .v-field.v-field--variant-outlined {
479
+ .v-field__outline {
480
+ --v-field-border-width: 1px;
481
+ }
482
+ }
483
+ }
484
+
485
+ .v-field__input {
486
+ color: $input-readonly-color !important;
454
487
  }
455
488
  }
456
489
  }
@@ -587,7 +620,34 @@ body {
587
620
 
588
621
  @include vfield();
589
622
 
590
- @include vfieldborder();
623
+ &:not(.ld-edit-list-box--readonly) {
624
+ .v-autocomplete {
625
+ & > .v-input__control > .v-field.v-field--variant-outlined {
626
+ @include vfieldoutline($input-border-color-default);
627
+ }
628
+
629
+ &:hover {
630
+ & > .v-input__control > .v-field.v-field--variant-outlined {
631
+ @include vfieldoutline($input-border-color-hover);
632
+ }
633
+
634
+ & > .v-input__append {
635
+ &:after {
636
+ border-color: $input-border-color-hover;
637
+ border-width: 1px;
638
+ }
639
+ }
640
+ }
641
+ }
642
+ }
643
+
644
+ &.ld-edit-list-box--readonly {
645
+ .v-autocomplete {
646
+ & > .v-input__control > .v-field.v-field--variant-outlined {
647
+ @include vfieldoutline($input-border-color-readonly);
648
+ }
649
+ }
650
+ }
591
651
 
592
652
  @include vfielddisabled();
593
653
 
@@ -679,6 +739,12 @@ body {
679
739
  .ld-textarea {
680
740
  @extend %custom-edit;
681
741
 
742
+ ::-webkit-resizer{
743
+ background-image: -webkit-repeating-radial-gradient(center center, hsla(220, 5%, 56%, 1), hsla(220, 5%, 56%, 1) 1px, transparent 1px, transparent 100%);
744
+ background-size: 3px 3px;
745
+ border-bottom-right-radius: var(--border-radius);
746
+ }
747
+
682
748
  $parent: '.ld-textarea';
683
749
 
684
750
  $props: (
@@ -713,14 +779,14 @@ body {
713
779
  line-height: calc($font + 6px);
714
780
  padding: $p;;
715
781
  }
716
- }
717
-
718
- .ld-label {
719
- &-content {
720
- font-size: $font;
782
+ .v-field__clearable {
783
+ top: 4px;
784
+ right: 4px;
721
785
  }
722
786
  }
723
787
 
788
+ @include inputlabel($parent, $size);
789
+
724
790
  .ld-textarea-help {
725
791
  height: $size;
726
792
  display: flex;
@@ -728,12 +794,6 @@ body {
728
794
  margin-left: 8px;
729
795
  }
730
796
 
731
- &.ld-textarea--label-on-top {
732
- .ld-label {
733
- height: $size;
734
- }
735
- }
736
-
737
797
  &.ld-textarea--clearable {
738
798
  .v-field {
739
799
  .v-field__input {
@@ -743,12 +803,7 @@ body {
743
803
  }
744
804
  }
745
805
 
746
- .v-input__details {
747
- .v-messages {
748
- font-size: calc($font - 2px);
749
- line-height: calc($font - 2px + 6px);
750
- }
751
- }
806
+ @include inputdetails();
752
807
  }
753
808
  }
754
809
 
@@ -773,12 +828,6 @@ body {
773
828
  .ld-text-markup {
774
829
  @extend %custom-edit;
775
830
 
776
- .ld-label {
777
- &-content {
778
- font-size: var(--text-body-s);
779
- }
780
- }
781
-
782
831
  &--focused {
783
832
  .md-editor-content {
784
833
  &:after {
@@ -835,13 +884,6 @@ body {
835
884
  }
836
885
 
837
886
  @include inputdetails();
838
-
839
- .v-input__details {
840
- .v-messages {
841
- font-size: var(--font-size);
842
- line-height: calc(var(--font-size) + 6px);
843
- }
844
- }
845
887
  }
846
888
 
847
889
  .v-select__content,
@@ -182,9 +182,6 @@ body {
182
182
 
183
183
  .v-window {
184
184
  background-color: var(--white);
185
- box-shadow:
186
- 1px 0 var(--grey-l-5),
187
- -1px 0 0 var(--grey-l-5);
188
185
  overflow-y: auto;
189
186
  height: 100%;
190
187
  width: 100%;
@@ -201,118 +198,117 @@ body {
201
198
  }
202
199
  }
203
200
 
204
- :deep() {
205
- .ld-tabs {
206
- .v-tabs {
207
- &--vertical {
208
- background: var(--grey-l-6);
209
-
210
- .v-tab {
211
- justify-content: flex-start;
212
- border: 1px solid var(--grey-l-5);
213
- border-bottom: none;
214
- border-radius: 0 !important;
215
- text-transform: none !important;
216
- width: 100%;
217
- min-width: auto !important;
218
-
219
- &--selected {
220
- background-color: var(--white);
221
- border-right-color: transparent;
222
- }
223
- }
224
-
225
- .v-tab:last-child {
226
- border-bottom: 1px solid var(--grey-l-5) !important;
227
- }
228
-
229
- .v-slide-group__content {
230
- flex-flow: column nowrap;
231
- height: 100% !important;
232
- width: 100% !important;
233
-
234
- .v-btn__content {
235
- text-overflow: ellipsis;
236
- display: inline-flex;
237
- justify-content: flex-start;
238
- gap: 4px;
239
- white-space: nowrap;
240
- overflow: hidden;
241
- }
242
- }
243
- }
244
- }
245
-
246
- .v-tabs.v-tabs--vertical.no-header {
247
- .v-tab:first-child {
248
- border-top: none;
249
- }
250
- }
251
-
252
-
253
- }
254
- .v-window {
255
- &.mobile {
256
- .tg-field {
257
- & > .v-row {
258
- & > .v-col {
259
- flex: 1 0 0 !important;
260
- }
261
- }
262
- .text-viewer-wrapper {
263
- .v-col {
264
- flex: 1 0 0 !important;
265
- }
266
- }
267
- }
268
- }
269
- }
270
-
271
- .v-slide-group--vertical {
272
- border-color: var(--grey-l-5);
273
- border: 1px;
274
- }
275
-
276
- .v-slide-group--vertical .v-tab__slider {
277
- width: 0px;
278
- }
279
-
280
-
281
- .v-tabs-bar {
282
- flex: none;
283
- height: fit-content;
284
- height: -moz-max-content;
285
- max-height: fit-content;
286
- max-height: -moz-max-content;
287
- z-index: 1;
288
- }
289
-
290
- .v-window-item {
291
- height: 100%;
292
- }
293
-
294
- .ld-tabs-mobile {
295
- &.hide-tabs {
296
- .v-tab {
297
- display: none !important;
298
- }
299
- }
300
-
301
- &.hide-body {
302
- .v-slide-group {
303
- width: 100% !important;
304
- }
305
- .v-window {
306
- display: none !important;
307
- }
308
- }
309
- }
310
- .v-tabs-mobile {
311
- .v-slide-group__content {
312
- .v-btn__content {
313
- display: block !important;
314
- }
315
- }
316
- }
317
- }
201
+ // :deep() {
202
+ // .ld-tabs {
203
+ // .v-tabs {
204
+ // &--vertical {
205
+ // background: var(--grey-l-6);
206
+
207
+ // .v-tab {
208
+ // justify-content: flex-start;
209
+ // border: 1px solid var(--grey-l-5);
210
+ // border-bottom: none;
211
+ // border-radius: 0 !important;
212
+ // text-transform: none !important;
213
+ // width: 100%;
214
+ // min-width: auto !important;
215
+
216
+ // &--selected {
217
+ // background-color: var(--white);
218
+ // border-right-color: transparent;
219
+ // }
220
+ // }
221
+
222
+ // .v-tab:last-child {
223
+ // border-bottom: 1px solid var(--grey-l-5) !important;
224
+ // }
225
+
226
+ // .v-slide-group__content {
227
+ // flex-flow: column nowrap;
228
+ // height: 100% !important;
229
+ // width: 100% !important;
230
+
231
+ // .v-btn__content {
232
+ // text-overflow: ellipsis;
233
+ // display: inline-flex;
234
+ // justify-content: flex-start;
235
+ // gap: 4px;
236
+ // white-space: nowrap;
237
+ // overflow: hidden;
238
+ // }
239
+ // }
240
+ // }
241
+ // }
242
+
243
+ // .v-tabs.v-tabs--vertical.no-header {
244
+ // .v-tab:first-child {
245
+ // border-top: none;
246
+ // }
247
+ // }
248
+
249
+
250
+ // }
251
+ // .v-window {
252
+ // &.mobile {
253
+ // .tg-field {
254
+ // & > .v-row {
255
+ // & > .v-col {
256
+ // flex: 1 0 0 !important;
257
+ // }
258
+ // }
259
+ // .text-viewer-wrapper {
260
+ // .v-col {
261
+ // flex: 1 0 0 !important;
262
+ // }
263
+ // }
264
+ // }
265
+ // }
266
+ // }
267
+
268
+ // .v-slide-group--vertical {
269
+ // border-color: var(--grey-l-5);
270
+ // border: 1px;
271
+ // }
272
+
273
+ // .v-slide-group--vertical .v-tab__slider {
274
+ // width: 0px;
275
+ // }
276
+
277
+ // .v-tabs-bar {
278
+ // flex: none;
279
+ // height: fit-content;
280
+ // height: -moz-max-content;
281
+ // max-height: fit-content;
282
+ // max-height: -moz-max-content;
283
+ // z-index: 1;
284
+ // }
285
+
286
+ // .v-window-item {
287
+ // height: 100%;
288
+ // }
289
+
290
+ // .ld-tabs-mobile {
291
+ // &.hide-tabs {
292
+ // .v-tab {
293
+ // display: none !important;
294
+ // }
295
+ // }
296
+
297
+ // &.hide-body {
298
+ // .v-slide-group {
299
+ // width: 100% !important;
300
+ // }
301
+ // .v-window {
302
+ // display: none !important;
303
+ // }
304
+ // }
305
+ // }
306
+ // .v-tabs-mobile {
307
+ // .v-slide-group__content {
308
+ // .v-btn__content {
309
+ // display: block !important;
310
+ // }
311
+ // }
312
+ // }
313
+ // }
318
314
  }
@@ -134,7 +134,6 @@ body {
134
134
  display: flex;
135
135
  flex-direction: column;
136
136
  justify-content: center;
137
- min-height: var(--input-height);
138
137
 
139
138
  .ld-label-content {
140
139
  color: var(--text);
@@ -15,3 +15,9 @@
15
15
  @function getSelector($class, $prefix) {
16
16
  @return selector.append($class, $prefix);
17
17
  }
18
+
19
+ @mixin not-class($className) {
20
+ &:not(#{$className}) {
21
+ @content;
22
+ }
23
+ }
@@ -49,7 +49,7 @@ export interface ldmuiOptions {
49
49
  language?: string;
50
50
  LdIcon?: {
51
51
  path: string;
52
- map: {
52
+ map?: {
53
53
  icons: Array<[string, string]>;
54
54
  };
55
55
  };
@@ -1 +1 @@
1
- (function webpackUniversalModuleDefinition(e,l){"object"===typeof exports&&"object"===typeof module?module.exports=l(require("@vuelidate/validators")):"function"===typeof define&&define.amd?define(["@vuelidate/validators"],l):"object"===typeof exports?exports["ldmui"]=l(require("@vuelidate/validators")):e["ldmui"]=l(e["@vuelidate/validators"])})(self,e=>(()=>{"use strict";var l={887:l=>{l.exports=e}},r={};function __webpack_require__(e){var u=r[e];if(void 0!==u)return u.exports;var t=r[e]={exports:{}};return l[e](t,t.exports,__webpack_require__),t.exports}(()=>{__webpack_require__.n=e=>{var l=e&&e.__esModule?()=>e["default"]:()=>e;return __webpack_require__.d(l,{a:l}),l}})(),(()=>{__webpack_require__.d=(e,l)=>{for(var r in l)__webpack_require__.o(l,r)&&!__webpack_require__.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:l[r]})}})(),(()=>{__webpack_require__.o=(e,l)=>Object.prototype.hasOwnProperty.call(e,l)})(),(()=>{__webpack_require__.r=e=>{"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}})();var u={};__webpack_require__.r(u),__webpack_require__.d(u,{alphaNumRule:()=>alphaNumRule,alphaRule:()=>alphaRule,betweenRule:()=>betweenRule,decimalRule:()=>decimalRule,default:()=>a,emailRule:()=>emailRule,integerRule:()=>integerRule,ipAddressRule:()=>ipAddressRule,macAddressRule:()=>macAddressRule,maxLengthRule:()=>maxLengthRule,maxValueRule:()=>maxValueRule,minValueRule:()=>minValueRule,numericRule:()=>numericRule,phoneRule:()=>phoneRule,requiredRule:()=>requiredRule,urlRule:()=>urlRule,validators:()=>o});var t=__webpack_require__(887);const requiredRule=(e,l)=>r=>{if(null==r||"string"===typeof r&&""===r)return e?`Поле ${e} обязательно`:l||"Это поле обязательно";const u=t.required.$validator(r,null,null);return!("boolean"!==typeof u||!u)||(e?`Поле ${e} обязательно`:l||"Это поле обязательно")},maxLengthRule=e=>l=>{const r=(0,t.maxLength)(e).$validator(l,null,null);return!("boolean"!==typeof r||!r)||`Значение должно быть меньше ${e} символов`},alphaRule=()=>e=>{const l=t.alpha.$validator(e,null,null);return!("boolean"!==typeof l||!l)||"Разрешены только латинские буквы"},alphaNumRule=()=>e=>{const l=t.alphaNum.$validator(e,null,null);return!("boolean"!==typeof l||!l)||"Разрешены только латинские буквы и цифры"},betweenRule=(e,l)=>r=>{const u=(0,t.between)(e,l).$validator(r,null,null);return!("boolean"!==typeof u||!u)||`Значение должно быть в диапазоне от ${e} до ${l}`},decimalRule=()=>e=>{const l=t.decimal.$validator(e,null,null);return!("boolean"!==typeof l||!l)||"Значение должно быть целым или дробным числом"},emailRule=()=>e=>{const l=t.email.$validator(e,null,null);return!("boolean"!==typeof l||!l)||"Неверный формат адреса эл.почты"},integerRule=()=>e=>{const l=t.integer.$validator(e,null,null);return!("boolean"!==typeof l||!l)||"Значение должно быть целым числом"},ipAddressRule=()=>e=>{const l=t.ipAddress.$validator(e,null,null);return!("boolean"!==typeof l||!l)||"Неправильный формат IP-адреса"},macAddressRule=()=>e=>{const l=(0,t.macAddress)(":").$validator(e,null,null);return!("boolean"!==typeof l||!l)||"Неправильный формат mac-адреса"},maxValueRule=e=>l=>{const r=(0,t.maxValue)(e).$validator(l,null,null);return!("boolean"!==typeof r||!r)||`Значение должно быть меньше ${e}`},minValueRule=e=>l=>{const r=(0,t.minValue)(e).$validator(l,null,null);return!("boolean"!==typeof r||!r)||`Значение должно быть больше ${e}`},numericRule=()=>e=>{const l=t.numeric.$validator(e,null,null);return!("boolean"!==typeof l||!l)||"Разрешены только цифры"},urlRule=()=>e=>{const l=t.url.$validator(e,null,null);return!("boolean"!==typeof l||!l)||"Неправильный формат URI"},phoneRule=()=>e=>{const l=/^[\d()+-]+$/;return l.test(e)||"Неправильный формат телефона"},o={requiredRule,maxLengthRule,alphaRule,alphaNumRule,betweenRule,decimalRule,emailRule,integerRule,ipAddressRule,macAddressRule,maxValueRule,minValueRule,numericRule,urlRule,phoneRule},a={};return u})());
1
+ (function webpackUniversalModuleDefinition(e,l){"object"===typeof exports&&"object"===typeof module?module.exports=l(require("@vuelidate/validators")):"function"===typeof define&&define.amd?define(["@vuelidate/validators"],l):"object"===typeof exports?exports["ldmui"]=l(require("@vuelidate/validators")):e["ldmui"]=l(e["@vuelidate/validators"])})(self,e=>(()=>{"use strict";var l={887(l){l.exports=e}},r={};function __webpack_require__(e){var u=r[e];if(void 0!==u)return u.exports;var t=r[e]={exports:{}};return l[e](t,t.exports,__webpack_require__),t.exports}(()=>{__webpack_require__.n=e=>{var l=e&&e.__esModule?()=>e["default"]:()=>e;return __webpack_require__.d(l,{a:l}),l}})(),(()=>{__webpack_require__.d=(e,l)=>{for(var r in l)__webpack_require__.o(l,r)&&!__webpack_require__.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:l[r]})}})(),(()=>{__webpack_require__.o=(e,l)=>Object.prototype.hasOwnProperty.call(e,l)})(),(()=>{__webpack_require__.r=e=>{"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}})();var u={};__webpack_require__.r(u),__webpack_require__.d(u,{alphaNumRule:()=>alphaNumRule,alphaRule:()=>alphaRule,betweenRule:()=>betweenRule,decimalRule:()=>decimalRule,default:()=>a,emailRule:()=>emailRule,integerRule:()=>integerRule,ipAddressRule:()=>ipAddressRule,macAddressRule:()=>macAddressRule,maxLengthRule:()=>maxLengthRule,maxValueRule:()=>maxValueRule,minValueRule:()=>minValueRule,numericRule:()=>numericRule,phoneRule:()=>phoneRule,requiredRule:()=>requiredRule,urlRule:()=>urlRule,validators:()=>o});var t=__webpack_require__(887);const requiredRule=(e,l)=>r=>{if(null==r||"string"===typeof r&&""===r)return e?`Поле ${e} обязательно`:l||"Это поле обязательно";const u=t.required.$validator(r,null,null);return!("boolean"!==typeof u||!u)||(e?`Поле ${e} обязательно`:l||"Это поле обязательно")},maxLengthRule=e=>l=>{const r=(0,t.maxLength)(e).$validator(l,null,null);return!("boolean"!==typeof r||!r)||`Значение должно быть меньше ${e} символов`},alphaRule=()=>e=>{const l=t.alpha.$validator(e,null,null);return!("boolean"!==typeof l||!l)||"Разрешены только латинские буквы"},alphaNumRule=()=>e=>{const l=t.alphaNum.$validator(e,null,null);return!("boolean"!==typeof l||!l)||"Разрешены только латинские буквы и цифры"},betweenRule=(e,l)=>r=>{const u=(0,t.between)(e,l).$validator(r,null,null);return!("boolean"!==typeof u||!u)||`Значение должно быть в диапазоне от ${e} до ${l}`},decimalRule=()=>e=>{const l=t.decimal.$validator(e,null,null);return!("boolean"!==typeof l||!l)||"Значение должно быть целым или дробным числом"},emailRule=()=>e=>{const l=t.email.$validator(e,null,null);return!("boolean"!==typeof l||!l)||"Неверный формат адреса эл.почты"},integerRule=()=>e=>{const l=t.integer.$validator(e,null,null);return!("boolean"!==typeof l||!l)||"Значение должно быть целым числом"},ipAddressRule=()=>e=>{const l=t.ipAddress.$validator(e,null,null);return!("boolean"!==typeof l||!l)||"Неправильный формат IP-адреса"},macAddressRule=()=>e=>{const l=(0,t.macAddress)(":").$validator(e,null,null);return!("boolean"!==typeof l||!l)||"Неправильный формат mac-адреса"},maxValueRule=e=>l=>{const r=(0,t.maxValue)(e).$validator(l,null,null);return!("boolean"!==typeof r||!r)||`Значение должно быть меньше ${e}`},minValueRule=e=>l=>{const r=(0,t.minValue)(e).$validator(l,null,null);return!("boolean"!==typeof r||!r)||`Значение должно быть больше ${e}`},numericRule=()=>e=>{const l=t.numeric.$validator(e,null,null);return!("boolean"!==typeof l||!l)||"Разрешены только цифры"},urlRule=()=>e=>{const l=t.url.$validator(e,null,null);return!("boolean"!==typeof l||!l)||"Неправильный формат URI"},phoneRule=()=>e=>{const l=/^[\d()+-]+$/;return l.test(e)||"Неправильный формат телефона"},o={requiredRule,maxLengthRule,alphaRule,alphaNumRule,betweenRule,decimalRule,emailRule,integerRule,ipAddressRule,macAddressRule,maxValueRule,minValueRule,numericRule,urlRule,phoneRule},a={};return u})());
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ldmjs/ui",
3
- "version": "2.0.0-beta.2",
3
+ "version": "2.0.0",
4
4
  "description": "ldm ui",
5
5
  "main": "dist/index.js",
6
6
  "engines": {
@@ -16,7 +16,8 @@
16
16
  "build:box:stage1": "cross-env NODE_ENV=production webpack --config config/webpack.config.box.js --progress --profile",
17
17
  "build:box:stage2": "node config/index.js",
18
18
  "build:box": "npm run build:box:stage1 && npm run build:box:stage2",
19
- "test": "jest --runInBand --no-cache",
19
+ "test": "npm run clear && jest --runInBand --no-cache",
20
+ "clear": "node config/clear.js",
20
21
  "lint": "npx eslint --cache --ext .ts src",
21
22
  "version": "node -v",
22
23
  "pub": "node config/publish.js && npm publish --access=public"
@@ -86,12 +87,12 @@
86
87
  "jest-transform-stub": "2.0.0",
87
88
  "lodash-es": "4.17.21",
88
89
  "markdown-it": "14.1.0",
89
- "material-design-icons-iconfont": "6.7.0",
90
90
  "md-editor-v3": "6.3.1",
91
91
  "mini-css-extract-plugin": "2.9.4",
92
92
  "mol_time_all": "1.1.1504",
93
93
  "postcss-loader": "8.2.0",
94
94
  "prettier": "3.6.2",
95
+ "prettier-eslint": "16.4.2",
95
96
  "sass": "1.93.2",
96
97
  "sass-loader": "16.0.3",
97
98
  "string-replace-loader": "3.1.0",
@@ -108,7 +109,7 @@
108
109
  "vue-loader": "17.4.2",
109
110
  "vue-property-decorator": "10.0.0-rc.3",
110
111
  "vue-screen-utils": "1.0.0-beta.13",
111
- "vuetify": "3.11.7",
112
+ "vuetify": "3.12.2",
112
113
  "webpack": "5.105.2",
113
114
  "webpack-cli": "6.0.1",
114
115
  "webpack-dev-server": "5.2.2",