nice-elements 1.11.0 → 1.11.1

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 (150) hide show
  1. package/.vscode/settings.json +18 -18
  2. package/CHANGELOG.md +510 -505
  3. package/LICENSE.md +21 -21
  4. package/README.md +98 -98
  5. package/bower.json +10 -10
  6. package/dist/nice.js +8397 -8356
  7. package/dist/nice.min.js +1 -1
  8. package/dist/style.css +7 -7
  9. package/dist/style.min.css +7 -7
  10. package/eslint.config.mjs +32 -32
  11. package/package.json +45 -45
  12. package/src/components/nice-button/nice-button.html +4 -4
  13. package/src/components/nice-button/nice-button.js +41 -41
  14. package/src/components/nice-button/nice-button.scss +16 -16
  15. package/src/components/nice-button-toggle/nice-button-toggle.html +9 -9
  16. package/src/components/nice-button-toggle/nice-button-toggle.js +23 -23
  17. package/src/components/nice-button-toggle/nice-button-toggle.scss +2 -2
  18. package/src/components/nice-calendar/nice-calendar.html +91 -91
  19. package/src/components/nice-calendar/nice-calendar.js +336 -336
  20. package/src/components/nice-calendar/nice-calendar.scss +285 -285
  21. package/src/components/nice-checkbox/nice-checkbox.html +5 -5
  22. package/src/components/nice-checkbox/nice-checkbox.js +34 -34
  23. package/src/components/nice-checkbox/nice-checkbox.scss +91 -91
  24. package/src/components/nice-choice/nice-choice.html +18 -18
  25. package/src/components/nice-choice/nice-choice.js +212 -212
  26. package/src/components/nice-choice/nice-choice.scss +110 -110
  27. package/src/components/nice-click-outside/nice-click-outside.js +105 -105
  28. package/src/components/nice-comment/nice-comment.html +10 -10
  29. package/src/components/nice-comment/nice-comment.js +71 -71
  30. package/src/components/nice-comment/nice-comment.scss +39 -39
  31. package/src/components/nice-date/nice-date.html +79 -79
  32. package/src/components/nice-date/nice-date.js +333 -333
  33. package/src/components/nice-date/nice-date.scss +305 -305
  34. package/src/components/nice-date-input/nice-date-input.html +41 -41
  35. package/src/components/nice-date-input/nice-date-input.js +111 -111
  36. package/src/components/nice-date-input/nice-date-input.scss +45 -45
  37. package/src/components/nice-date-range/nice-date-range.html +15 -15
  38. package/src/components/nice-date-range/nice-date-range.js +78 -78
  39. package/src/components/nice-date-range/nice-date-range.scss +390 -390
  40. package/src/components/nice-datetime-picker/nice-datetime-picker.html +29 -29
  41. package/src/components/nice-datetime-picker/nice-datetime-picker.js +89 -89
  42. package/src/components/nice-datetime-picker/nice-datetime-picker.scss +428 -428
  43. package/src/components/nice-datetimerange-picker/nice-datetimerange-picker.html +55 -55
  44. package/src/components/nice-datetimerange-picker/nice-datetimerange-picker.js +248 -248
  45. package/src/components/nice-datetimerange-picker/nice-datetimerange-picker.scss +73 -73
  46. package/src/components/nice-datetimerange-picker-2/nice-datetimerange-picker-2.html +44 -44
  47. package/src/components/nice-datetimerange-picker-2/nice-datetimerange-picker-2.js +175 -175
  48. package/src/components/nice-datetimerange-picker-2/nice-datetimerange-picker-2.scss +127 -127
  49. package/src/components/nice-dropdown/nice-dropdown.html +61 -61
  50. package/src/components/nice-dropdown/nice-dropdown.js +517 -517
  51. package/src/components/nice-dropdown/nice-dropdown.scss +262 -262
  52. package/src/components/nice-dropdown-date/nice-dropdown-date.html +28 -28
  53. package/src/components/nice-dropdown-date/nice-dropdown-date.js +132 -132
  54. package/src/components/nice-dropdown-date/nice-dropdown-date.scss +87 -87
  55. package/src/components/nice-dropdown-old/nice-dropdown-old.html +44 -44
  56. package/src/components/nice-dropdown-old/nice-dropdown-old.js +330 -330
  57. package/src/components/nice-dropdown-old/nice-dropdown-old.scss +129 -129
  58. package/src/components/nice-dtp/nice-dtp.html +91 -91
  59. package/src/components/nice-dtp/nice-dtp.js +835 -835
  60. package/src/components/nice-help/nice-help.html +6 -6
  61. package/src/components/nice-help/nice-help.js +58 -58
  62. package/src/components/nice-help/nice-help.scss +78 -78
  63. package/src/components/nice-input/nice-input.html +48 -48
  64. package/src/components/nice-input/nice-input.js +246 -245
  65. package/src/components/nice-input/nice-input.scss +130 -130
  66. package/src/components/nice-label/nice-label.html +10 -10
  67. package/src/components/nice-label/nice-label.js +32 -32
  68. package/src/components/nice-loader/nice-loader.html +6 -6
  69. package/src/components/nice-loader/nice-loader.js +28 -28
  70. package/src/components/nice-loader/nice-loader.scss +47 -47
  71. package/src/components/nice-no-data/nice-no-data.html +3 -3
  72. package/src/components/nice-no-data/nice-no-data.js +27 -27
  73. package/src/components/nice-no-data/nice-no-data.scss +26 -26
  74. package/src/components/nice-notification/nice-notification.html +3 -3
  75. package/src/components/nice-notification/nice-notification.js +124 -124
  76. package/src/components/nice-notification/nice-notification.scss +66 -66
  77. package/src/components/nice-number/nice-number.html +40 -40
  78. package/src/components/nice-number/nice-number.js +172 -172
  79. package/src/components/nice-number/nice-number.scss +18 -18
  80. package/src/components/nice-on-scroll/nice-on-scroll.js +17 -17
  81. package/src/components/nice-percent/nice-percent.html +24 -24
  82. package/src/components/nice-percent/nice-percent.js +95 -95
  83. package/src/components/nice-pill/nice-pill.html +3 -3
  84. package/src/components/nice-pill/nice-pill.js +29 -29
  85. package/src/components/nice-pill/nice-pill.scss +25 -25
  86. package/src/components/nice-popup/nice-popup.html +6 -6
  87. package/src/components/nice-popup/nice-popup.js +122 -122
  88. package/src/components/nice-popup/nice-popup.scss +43 -43
  89. package/src/components/nice-progress-bar/nice-progress-bar.html +15 -15
  90. package/src/components/nice-progress-bar/nice-progress-bar.js +55 -55
  91. package/src/components/nice-progress-bar/nice-progress-bar.scss +47 -47
  92. package/src/components/nice-quantity/nice-quantity.html +22 -22
  93. package/src/components/nice-quantity/nice-quantity.js +57 -57
  94. package/src/components/nice-quantity/nice-quantity.scss +51 -51
  95. package/src/components/nice-search/nice-search.html +44 -44
  96. package/src/components/nice-search/nice-search.js +243 -243
  97. package/src/components/nice-search/nice-search.scss +90 -90
  98. package/src/components/nice-search2/nice-search2.html +32 -32
  99. package/src/components/nice-search2/nice-search2.js +267 -267
  100. package/src/components/nice-search2/nice-search2.scss +80 -80
  101. package/src/components/nice-slot/nice-slot.html +10 -10
  102. package/src/components/nice-slot/nice-slot.js +31 -31
  103. package/src/components/nice-steps/nice-steps.scss +81 -81
  104. package/src/components/nice-svgs/nice-svgs.html +1275 -1275
  105. package/src/components/nice-svgs/nice-svgs.js +19 -19
  106. package/src/components/nice-table/nice-table.html +38 -38
  107. package/src/components/nice-table/nice-table.js +60 -60
  108. package/src/components/nice-table/nice-table.scss +112 -112
  109. package/src/components/nice-time-picker/nice-time-picker.html +43 -43
  110. package/src/components/nice-time-picker/nice-time-picker.js +85 -85
  111. package/src/components/nice-time-picker/nice-time-picker.scss +37 -37
  112. package/src/components/nice-title/nice-title.html +3 -3
  113. package/src/components/nice-title/nice-title.js +21 -21
  114. package/src/components/nice-toast/nice-toast.html +2 -2
  115. package/src/components/nice-toast/nice-toast.js +56 -56
  116. package/src/components/nice-toast/nice-toast.scss +74 -74
  117. package/src/components/nice-toggle/nice-toggle.html +12 -12
  118. package/src/components/nice-toggle/nice-toggle.js +55 -55
  119. package/src/components/nice-toggle/nice-toggle.scss +131 -131
  120. package/src/components/nice-tooltip/_nice-tooltip.scss +55 -55
  121. package/src/components/nice-tooltip/nice-tooltip.js +84 -84
  122. package/src/components/nice-upload/nice-upload.html +22 -22
  123. package/src/components/nice-upload/nice-upload.js +159 -159
  124. package/src/components/nice-upload/nice-upload.scss +85 -85
  125. package/src/components/nice-view/_nice-view.scss +62 -62
  126. package/src/components/nice-view/nice-view.html +12 -12
  127. package/src/components/nice-view/nice-view.js +30 -30
  128. package/src/components/nice-virtual-scroll/_nice-virtual-scroll.scss +17 -17
  129. package/src/components/nice-virtual-scroll/nice-virtual-scroll.html +12 -12
  130. package/src/components/nice-virtual-scroll/nice-virtual-scroll.js +70 -70
  131. package/src/components/nice-wrapper/_nice-wrapper.scss +87 -87
  132. package/src/components/nice-wrapper/nice-wrapper.html +12 -12
  133. package/src/components/nice-wrapper/nice-wrapper.js +44 -44
  134. package/src/components/nice-yesno/nice-yesno.html +14 -14
  135. package/src/components/nice-yesno/nice-yesno.js +111 -111
  136. package/src/components/nice-yesno/nice-yesno.scss +95 -95
  137. package/src/filters/nice-date.js +17 -17
  138. package/src/filters/nice-highlight.js +16 -16
  139. package/src/modals/nice-multilangual-modal/nice-multilangual-modal.html +30 -30
  140. package/src/modals/nice-multilangual-modal/nice-multilangual-modal.js +67 -67
  141. package/src/modals/nice-multilangual-modal/nice-multilangual-modal.scss +19 -19
  142. package/src/nice.js +2 -2
  143. package/src/services/nice-service.js +22 -22
  144. package/src/styles/_bootstrap-variables.scss +178 -178
  145. package/src/styles/_nice-buttons.scss +612 -612
  146. package/src/styles/_nice-common.scss +471 -471
  147. package/src/styles/_nice-ngdialog.scss +85 -85
  148. package/src/styles/_nice-spacing.scss +283 -283
  149. package/src/styles/_nice.scss +70 -70
  150. package/src/styles/_variables.scss +191 -191
@@ -1,133 +1,133 @@
1
- 'use strict';
2
-
3
- /**
4
- * @ngdoc directive
5
- * @name niceElements.directive:niceDropdownDate
6
- * @description
7
- * # niceDropdownDate
8
- */
9
- angular.module('niceElements')
10
- .directive('niceDropdownDate', function (gettextCatalog) {
11
- return {
12
- restrict: 'E',
13
- replace: true,
14
- templateUrl: "src/components/nice-dropdown-date/nice-dropdown-date.html",
15
- scope: {
16
- model: '=',
17
- niceTitle: '@',
18
- title: '@',
19
- fieldWidth: '@',
20
- labelWidth: '@',
21
- noMargin: '@',
22
- isDisabled: '=',
23
- numYears: '@',
24
- startingYear: '@',
25
- mature: '@',
26
- help: '@',
27
- isInline: '=',
28
- onChange: '&?',
29
- required: '='
30
- },
31
- controller: function ($scope, $timeout) {
32
- $scope.days = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31];
33
- $scope.months = [
34
- { value: 0, name: gettextCatalog.getString('Jan', null, 'Nice') },
35
- { value: 1, name: gettextCatalog.getString('Feb', null, 'Nice') },
36
- { value: 2, name: gettextCatalog.getString('Mar', null, 'Nice') },
37
- { value: 3, name: gettextCatalog.getString('Apr', null, 'Nice') },
38
- { value: 4, name: gettextCatalog.getString('May', null, 'Nice') },
39
- { value: 5, name: gettextCatalog.getString('Jun', null, 'Nice') },
40
- { value: 6, name: gettextCatalog.getString('Jul', null, 'Nice') },
41
- { value: 7, name: gettextCatalog.getString('Aug', null, 'Nice') },
42
- { value: 8, name: gettextCatalog.getString('Sep', null, 'Nice') },
43
- { value: 9, name: gettextCatalog.getString('Oct', null, 'Nice') },
44
- { value: 10, name: gettextCatalog.getString('Nov', null, 'Nice') },
45
- { value: 11, name: gettextCatalog.getString('Dec', null, 'Nice') }
46
- ];
47
-
48
-
49
- // Set the years drop down from attributes or defaults
50
- const currentYear = parseInt($scope.startingYear, 10) || new Date().getFullYear();
51
- const numYears = parseInt($scope.numYears, 10) || 100;
52
- const oldestYear = currentYear - numYears;
53
- let newestYear = currentYear;
54
-
55
-
56
- // If mature
57
- if ($scope.mature) newestYear -= 17;
58
-
59
-
60
- // Create years array
61
- $scope.years = [];
62
- for (let i = currentYear; i >= oldestYear; i--) {
63
- if (i <= newestYear) {
64
- $scope.years.push(i);
65
- }
66
- }
67
-
68
-
69
- // Split the current date into sections
70
- $scope.dateFields = {};
71
-
72
-
73
- // Watch for model change
74
- $scope.$watch('model', function (newDate, oldDate) {
75
- if (newDate && newDate != oldDate) {
76
- const date = moment(newDate);
77
- $scope.dateFields.day = date.get('date');
78
- $scope.dateFields.month = date.get('month');
79
- $scope.dateFields.year = date.get('year');
80
- $scope.checkDate();
81
- }
82
- });
83
-
84
-
85
- // validate that the date selected is accurate
86
- $scope.checkDate = function () {
87
- const date = moment($scope.dateFields.day + "." + ($scope.dateFields.month + 1) + "." + $scope.dateFields.year, "D.M.YYYY");
88
-
89
- if (date.isValid()) {
90
- // Format
91
- $scope.model = date.format();
92
- if ($scope.onChange) {
93
- $timeout(function () {
94
- $scope.onChange({ model: $scope.model });
95
- })
96
- }
97
-
98
- // Change dates
99
- $scope.days = [];
100
- for (let i = 1; i <= date.daysInMonth(); i++) {
101
- $scope.days.push(i);
102
- }
103
-
104
- // Valid
105
- if ($scope.dropdownDateForm) {
106
- $scope.dropdownDateForm.$setValidity('validDate', true);
107
- $scope.dropdownDateForm.$setDirty();
108
- }
109
- } else {
110
- // Invalid
111
- if ($scope.dropdownDateForm) $scope.dropdownDateForm.$setValidity('validDate', false);
112
- }
113
- };
114
-
115
-
116
- // Set current date
117
- if (!$scope.model) {
118
- const date = moment();
119
- $scope.dateFields.day = date.get('date');
120
- $scope.dateFields.month = date.get('month');
121
- $scope.dateFields.year = date.get('year');
122
- if ($scope.mature) $scope.dateFields.year -= 18;
123
- $scope.checkDate();
124
- } else {
125
- const date = moment($scope.model);
126
- $scope.dateFields.day = date.get('date');
127
- $scope.dateFields.month = date.get('month');
128
- $scope.dateFields.year = date.get('year');
129
- $scope.checkDate();
130
- }
131
- }
132
- };
1
+ 'use strict';
2
+
3
+ /**
4
+ * @ngdoc directive
5
+ * @name niceElements.directive:niceDropdownDate
6
+ * @description
7
+ * # niceDropdownDate
8
+ */
9
+ angular.module('niceElements')
10
+ .directive('niceDropdownDate', function (gettextCatalog) {
11
+ return {
12
+ restrict: 'E',
13
+ replace: true,
14
+ templateUrl: "src/components/nice-dropdown-date/nice-dropdown-date.html",
15
+ scope: {
16
+ model: '=',
17
+ niceTitle: '@',
18
+ title: '@',
19
+ fieldWidth: '@',
20
+ labelWidth: '@',
21
+ noMargin: '@',
22
+ isDisabled: '=',
23
+ numYears: '@',
24
+ startingYear: '@',
25
+ mature: '@',
26
+ help: '@',
27
+ isInline: '=',
28
+ onChange: '&?',
29
+ required: '='
30
+ },
31
+ controller: function ($scope, $timeout) {
32
+ $scope.days = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31];
33
+ $scope.months = [
34
+ { value: 0, name: gettextCatalog.getString('Jan', null, 'Nice') },
35
+ { value: 1, name: gettextCatalog.getString('Feb', null, 'Nice') },
36
+ { value: 2, name: gettextCatalog.getString('Mar', null, 'Nice') },
37
+ { value: 3, name: gettextCatalog.getString('Apr', null, 'Nice') },
38
+ { value: 4, name: gettextCatalog.getString('May', null, 'Nice') },
39
+ { value: 5, name: gettextCatalog.getString('Jun', null, 'Nice') },
40
+ { value: 6, name: gettextCatalog.getString('Jul', null, 'Nice') },
41
+ { value: 7, name: gettextCatalog.getString('Aug', null, 'Nice') },
42
+ { value: 8, name: gettextCatalog.getString('Sep', null, 'Nice') },
43
+ { value: 9, name: gettextCatalog.getString('Oct', null, 'Nice') },
44
+ { value: 10, name: gettextCatalog.getString('Nov', null, 'Nice') },
45
+ { value: 11, name: gettextCatalog.getString('Dec', null, 'Nice') }
46
+ ];
47
+
48
+
49
+ // Set the years drop down from attributes or defaults
50
+ const currentYear = parseInt($scope.startingYear, 10) || new Date().getFullYear();
51
+ const numYears = parseInt($scope.numYears, 10) || 100;
52
+ const oldestYear = currentYear - numYears;
53
+ let newestYear = currentYear;
54
+
55
+
56
+ // If mature
57
+ if ($scope.mature) newestYear -= 17;
58
+
59
+
60
+ // Create years array
61
+ $scope.years = [];
62
+ for (let i = currentYear; i >= oldestYear; i--) {
63
+ if (i <= newestYear) {
64
+ $scope.years.push(i);
65
+ }
66
+ }
67
+
68
+
69
+ // Split the current date into sections
70
+ $scope.dateFields = {};
71
+
72
+
73
+ // Watch for model change
74
+ $scope.$watch('model', function (newDate, oldDate) {
75
+ if (newDate && newDate != oldDate) {
76
+ const date = moment(newDate);
77
+ $scope.dateFields.day = date.get('date');
78
+ $scope.dateFields.month = date.get('month');
79
+ $scope.dateFields.year = date.get('year');
80
+ $scope.checkDate();
81
+ }
82
+ });
83
+
84
+
85
+ // validate that the date selected is accurate
86
+ $scope.checkDate = function () {
87
+ const date = moment($scope.dateFields.day + "." + ($scope.dateFields.month + 1) + "." + $scope.dateFields.year, "D.M.YYYY");
88
+
89
+ if (date.isValid()) {
90
+ // Format
91
+ $scope.model = date.format();
92
+ if ($scope.onChange) {
93
+ $timeout(function () {
94
+ $scope.onChange({ model: $scope.model });
95
+ })
96
+ }
97
+
98
+ // Change dates
99
+ $scope.days = [];
100
+ for (let i = 1; i <= date.daysInMonth(); i++) {
101
+ $scope.days.push(i);
102
+ }
103
+
104
+ // Valid
105
+ if ($scope.dropdownDateForm) {
106
+ $scope.dropdownDateForm.$setValidity('validDate', true);
107
+ $scope.dropdownDateForm.$setDirty();
108
+ }
109
+ } else {
110
+ // Invalid
111
+ if ($scope.dropdownDateForm) $scope.dropdownDateForm.$setValidity('validDate', false);
112
+ }
113
+ };
114
+
115
+
116
+ // Set current date
117
+ if (!$scope.model) {
118
+ const date = moment();
119
+ $scope.dateFields.day = date.get('date');
120
+ $scope.dateFields.month = date.get('month');
121
+ $scope.dateFields.year = date.get('year');
122
+ if ($scope.mature) $scope.dateFields.year -= 18;
123
+ $scope.checkDate();
124
+ } else {
125
+ const date = moment($scope.model);
126
+ $scope.dateFields.day = date.get('date');
127
+ $scope.dateFields.month = date.get('month');
128
+ $scope.dateFields.year = date.get('year');
129
+ $scope.checkDate();
130
+ }
131
+ }
132
+ };
133
133
  });
@@ -1,87 +1,87 @@
1
- .nice-dropdown-date {
2
- display: block;
3
-
4
- .form-inline {
5
- display: flex;
6
- }
7
-
8
- .nice-dropdown-date-day,
9
- .nice-dropdown-date-month,
10
- .nice-dropdown-date-year {
11
- float: left;
12
- position: relative;
13
-
14
- &:after {
15
- content: " ";
16
- position: absolute;
17
- top: 50%;
18
- right: 10px;
19
- width: 0;
20
- height: 0;
21
- border-style: solid;
22
- border-width: 4px 4px 0 4px;
23
- margin-top: -2px;
24
- border-color: $nice-border-color transparent transparent transparent;
25
- z-index: 3;
26
- }
27
- }
28
-
29
- .nice-dropdown-date-day,
30
- .nice-dropdown-date-month {
31
- margin-right: 10px;
32
- }
33
-
34
- .nice-dropdown-date-day {
35
- width: 30%;
36
- }
37
-
38
- .nice-dropdown-date-month {
39
- width: 40%;
40
- }
41
-
42
- .nice-dropdown-date-year {
43
- width: 30%;
44
- }
45
-
46
- select {
47
- width: 100% !important;
48
- -webkit-appearance: none;
49
- -moz-appearance: none;
50
- appearance: none;
51
- outline: 0;
52
- border-radius: $nice-border-radius !important;
53
- border: 1px solid $nice-border-color;
54
- position: relative;
55
- z-index: 2;
56
- background: transparent;
57
-
58
- // option {
59
- // background: var(--nice-primary-color);
60
- // }
61
-
62
- &:disabled {
63
- cursor: not-allowed;
64
- background: $nice-dropdown-disabled-bg !important;
65
- border-color: var(--nice-border-color);
66
-
67
- &:active,
68
- &:focus {
69
- outline: 0 none;
70
- }
71
- }
72
-
73
- &:hover {
74
- background: $nice-dropdown-hover-bg;
75
- border-color: var(--nice-border-color);
76
- color: $nice-dropdown-hover-color;
77
- }
78
-
79
- &:active,
80
- &:focus {
81
- background: $nice-focus-bg !important;
82
- color: $nice-focus-color !important;
83
- border-color: var(--nice-border-color);
84
- @extend .nice-focus;
85
- }
86
- }
87
- }
1
+ .nice-dropdown-date {
2
+ display: block;
3
+
4
+ .form-inline {
5
+ display: flex;
6
+ }
7
+
8
+ .nice-dropdown-date-day,
9
+ .nice-dropdown-date-month,
10
+ .nice-dropdown-date-year {
11
+ float: left;
12
+ position: relative;
13
+
14
+ &:after {
15
+ content: " ";
16
+ position: absolute;
17
+ top: 50%;
18
+ right: 10px;
19
+ width: 0;
20
+ height: 0;
21
+ border-style: solid;
22
+ border-width: 4px 4px 0 4px;
23
+ margin-top: -2px;
24
+ border-color: $nice-border-color transparent transparent transparent;
25
+ z-index: 3;
26
+ }
27
+ }
28
+
29
+ .nice-dropdown-date-day,
30
+ .nice-dropdown-date-month {
31
+ margin-right: 10px;
32
+ }
33
+
34
+ .nice-dropdown-date-day {
35
+ width: 30%;
36
+ }
37
+
38
+ .nice-dropdown-date-month {
39
+ width: 40%;
40
+ }
41
+
42
+ .nice-dropdown-date-year {
43
+ width: 30%;
44
+ }
45
+
46
+ select {
47
+ width: 100% !important;
48
+ -webkit-appearance: none;
49
+ -moz-appearance: none;
50
+ appearance: none;
51
+ outline: 0;
52
+ border-radius: $nice-border-radius !important;
53
+ border: 1px solid $nice-border-color;
54
+ position: relative;
55
+ z-index: 2;
56
+ background: transparent;
57
+
58
+ // option {
59
+ // background: var(--nice-primary-color);
60
+ // }
61
+
62
+ &:disabled {
63
+ cursor: not-allowed;
64
+ background: $nice-dropdown-disabled-bg !important;
65
+ border-color: var(--nice-border-color);
66
+
67
+ &:active,
68
+ &:focus {
69
+ outline: 0 none;
70
+ }
71
+ }
72
+
73
+ &:hover {
74
+ background: $nice-dropdown-hover-bg;
75
+ border-color: var(--nice-border-color);
76
+ color: $nice-dropdown-hover-color;
77
+ }
78
+
79
+ &:active,
80
+ &:focus {
81
+ background: $nice-focus-bg !important;
82
+ color: $nice-focus-color !important;
83
+ border-color: var(--nice-border-color);
84
+ @extend .nice-focus;
85
+ }
86
+ }
87
+ }
@@ -1,45 +1,45 @@
1
- <div class="nice-component nice-dropdown-old" ng-class="{ 'margin-bottom-0': noMargin, 'nice-component-inline': isInline }">
2
- <div class="row">
3
- <!------------------------- Title ------------------------->
4
- <nice-title text="title || niceTitle" help="help" required="required" label-width="labelWidth"></nice-title>
5
-
6
- <!------------------------- Field ------------------------->
7
- <div class="nice-field col-xs-12" ng-class="fieldWidth ? fieldWidth : 'col-sm-8'">
8
- <div ng-class="addButtonEnable && !isDisabled ? 'input-group': ''">
9
- <div class="btn-group" dropdown is-open="status.isopen" ng-class="{ 'disabled': isDisabled || emptyList }">
10
- <button type="button" class="btn btn-block btn-dropdown dropdown-toggle" title="{{ getLabel(internalSelected) }}" dropdown-toggle ng-disabled="isDisabled || emptyList">
11
- <span ng-if="internalSelected.color_hex_code" class="dropdown-color" ng-style="{'background': internalSelected.color_hex_code}"></span>
12
- <span ng-if="!multiple">{{ getLabel(internalSelected) }}</span>
13
-
14
- <span ng-if="multiple">
15
- <!--<span ng-repeat="item in internalSelected"><span ng-if="$index > 0">, </span>{{ getLabel(item) }}</span>-->
16
- <span ng-if="internalSelected.length > 1">{{ internalSelected.length }} <translate translate-context="Nice">selected</translate></span>
17
- <span ng-if="internalSelected.length == 1">{{ getLabel(internalSelected[0]) }}</span>
18
- <span ng-if="internalSelected.length == 0" translate translate-context="Nice">None</span>
19
- </span>
20
-
21
- <!--<span ng-if="showTax && internalSelected.value">{{ internalSelected.value * 100 }}%</span>-->
22
- <span class="caret"></span>
23
- </button>
24
-
25
- <ul id="{{id}}" class="dropdown-menu" role="menu">
26
- <li id="{{id}}-{{$index}}" ng-repeat="item in internalList" ng-click="clicked(item)">
27
- <a href>
28
- <span class="choice-checkbox" ng-if="multiple" ng-class="{ 'selected' : isItemSelected(item) }"><i class="fa fa-check"></i></span>
29
- <span ng-if="item.color_hex_code" class="dropdown-color" ng-style="{'background': item.color_hex_code}"></span>
30
- <span ng-class="{'multiple-item': multiple}">{{ getLabel(item) }}</span>
31
- <!--<span ng-if="showTax && item.value">{{ item.value * 100 }}%</span>-->
32
- </a>
33
- </li>
34
- </ul>
35
- </div>
36
-
37
- <span class="input-group-btn" ng-if="addButtonEnable && !isDisabled">
38
- <button type="button" class="btn btn-primary" ng-click="addButtonFunction()">+</button>
39
- </span>
40
- </div>
41
- </div>
42
- </div>
43
- <!--Needed for intercepting form changes ($dirty)!-->
44
- <div ng-form="formDropdown"></div>
1
+ <div class="nice-component nice-dropdown-old" ng-class="{ 'margin-bottom-0': noMargin, 'nice-component-inline': isInline }">
2
+ <div class="row">
3
+ <!------------------------- Title ------------------------->
4
+ <nice-title text="title || niceTitle" help="help" required="required" label-width="labelWidth"></nice-title>
5
+
6
+ <!------------------------- Field ------------------------->
7
+ <div class="nice-field col-xs-12" ng-class="fieldWidth ? fieldWidth : 'col-sm-8'">
8
+ <div ng-class="addButtonEnable && !isDisabled ? 'input-group': ''">
9
+ <div class="btn-group" dropdown is-open="status.isopen" ng-class="{ 'disabled': isDisabled || emptyList }">
10
+ <button type="button" class="btn btn-block btn-dropdown dropdown-toggle" title="{{ getLabel(internalSelected) }}" dropdown-toggle ng-disabled="isDisabled || emptyList">
11
+ <span ng-if="internalSelected.color_hex_code" class="dropdown-color" ng-style="{'background': internalSelected.color_hex_code}"></span>
12
+ <span ng-if="!multiple">{{ getLabel(internalSelected) }}</span>
13
+
14
+ <span ng-if="multiple">
15
+ <!--<span ng-repeat="item in internalSelected"><span ng-if="$index > 0">, </span>{{ getLabel(item) }}</span>-->
16
+ <span ng-if="internalSelected.length > 1">{{ internalSelected.length }} <translate translate-context="Nice">selected</translate></span>
17
+ <span ng-if="internalSelected.length == 1">{{ getLabel(internalSelected[0]) }}</span>
18
+ <span ng-if="internalSelected.length == 0" translate translate-context="Nice">None</span>
19
+ </span>
20
+
21
+ <!--<span ng-if="showTax && internalSelected.value">{{ internalSelected.value * 100 }}%</span>-->
22
+ <span class="caret"></span>
23
+ </button>
24
+
25
+ <ul id="{{id}}" class="dropdown-menu" role="menu">
26
+ <li id="{{id}}-{{$index}}" ng-repeat="item in internalList" ng-click="clicked(item)">
27
+ <a href>
28
+ <span class="choice-checkbox" ng-if="multiple" ng-class="{ 'selected' : isItemSelected(item) }"><i class="fa fa-check"></i></span>
29
+ <span ng-if="item.color_hex_code" class="dropdown-color" ng-style="{'background': item.color_hex_code}"></span>
30
+ <span ng-class="{'multiple-item': multiple}">{{ getLabel(item) }}</span>
31
+ <!--<span ng-if="showTax && item.value">{{ item.value * 100 }}%</span>-->
32
+ </a>
33
+ </li>
34
+ </ul>
35
+ </div>
36
+
37
+ <span class="input-group-btn" ng-if="addButtonEnable && !isDisabled">
38
+ <button type="button" class="btn btn-primary" ng-click="addButtonFunction()">+</button>
39
+ </span>
40
+ </div>
41
+ </div>
42
+ </div>
43
+ <!--Needed for intercepting form changes ($dirty)!-->
44
+ <div ng-form="formDropdown"></div>
45
45
  </div>