nice-elements 1.9.16 → 1.10.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 (143) hide show
  1. package/.vscode/settings.json +17 -17
  2. package/CHANGELOG.md +417 -401
  3. package/LICENSE.md +21 -21
  4. package/README.md +95 -93
  5. package/bower.json +10 -10
  6. package/dist/nice.js +8102 -7930
  7. package/dist/nice.min.js +1 -1
  8. package/dist/style.css +153 -9
  9. package/dist/style.css.map +3 -1
  10. package/dist/style.min.css +8 -8
  11. package/package.json +42 -40
  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 +334 -334
  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 +33 -33
  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 +210 -210
  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 +69 -69
  30. package/src/components/nice-comment/nice-comment.scss +39 -39
  31. package/src/components/nice-date/nice-date.html +74 -74
  32. package/src/components/nice-date/nice-date.js +327 -327
  33. package/src/components/nice-date/nice-date.scss +302 -302
  34. package/src/components/nice-date-input/nice-date-input.html +41 -41
  35. package/src/components/nice-date-input/nice-date-input.js +109 -109
  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 +76 -76
  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 +87 -87
  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 +246 -246
  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 +172 -172
  48. package/src/components/nice-datetimerange-picker-2/nice-datetimerange-picker-2.scss +127 -127
  49. package/src/components/nice-dropdown/nice-dropdown.html +60 -60
  50. package/src/components/nice-dropdown/nice-dropdown.js +489 -489
  51. package/src/components/nice-dropdown/nice-dropdown.scss +249 -249
  52. package/src/components/nice-dropdown-date/nice-dropdown-date.html +28 -28
  53. package/src/components/nice-dropdown-date/nice-dropdown-date.js +126 -126
  54. package/src/components/nice-dropdown-date/nice-dropdown-date.scss +82 -82
  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 +833 -833
  60. package/src/components/nice-help/nice-help.html +6 -6
  61. package/src/components/nice-help/nice-help.js +55 -55
  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 +244 -244
  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 +30 -30
  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 +4 -0
  72. package/src/components/nice-no-data/nice-no-data.js +28 -0
  73. package/src/components/nice-no-data/nice-no-data.scss +31 -0
  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 +169 -169
  79. package/src/components/nice-number/nice-number.scss +18 -18
  80. package/src/components/nice-percent/nice-percent.html +24 -24
  81. package/src/components/nice-percent/nice-percent.js +94 -94
  82. package/src/components/nice-pill/nice-pill.html +3 -3
  83. package/src/components/nice-pill/nice-pill.js +29 -29
  84. package/src/components/nice-pill/nice-pill.scss +25 -25
  85. package/src/components/nice-popup/nice-popup.html +6 -6
  86. package/src/components/nice-popup/nice-popup.js +122 -122
  87. package/src/components/nice-popup/nice-popup.scss +43 -43
  88. package/src/components/nice-progress-bar/nice-progress-bar.html +15 -15
  89. package/src/components/nice-progress-bar/nice-progress-bar.js +54 -54
  90. package/src/components/nice-progress-bar/nice-progress-bar.scss +47 -47
  91. package/src/components/nice-quantity/nice-quantity.html +22 -22
  92. package/src/components/nice-quantity/nice-quantity.js +55 -55
  93. package/src/components/nice-quantity/nice-quantity.scss +51 -51
  94. package/src/components/nice-search/nice-search.html +44 -44
  95. package/src/components/nice-search/nice-search.js +239 -239
  96. package/src/components/nice-search/nice-search.scss +90 -90
  97. package/src/components/nice-search2/nice-search2.html +32 -32
  98. package/src/components/nice-search2/nice-search2.js +264 -264
  99. package/src/components/nice-search2/nice-search2.scss +80 -80
  100. package/src/components/nice-slot/nice-slot.html +10 -10
  101. package/src/components/nice-slot/nice-slot.js +29 -29
  102. package/src/components/nice-steps/nice-steps.scss +81 -81
  103. package/src/components/nice-svgs/nice-svgs.html +1262 -1262
  104. package/src/components/nice-svgs/nice-svgs.js +16 -16
  105. package/src/components/nice-table/nice-table.html +38 -0
  106. package/src/components/nice-table/nice-table.js +61 -0
  107. package/src/components/nice-table/nice-table.scss +112 -0
  108. package/src/components/nice-time-picker/nice-time-picker.html +43 -43
  109. package/src/components/nice-time-picker/nice-time-picker.js +83 -83
  110. package/src/components/nice-time-picker/nice-time-picker.scss +37 -37
  111. package/src/components/nice-title/nice-title.html +3 -3
  112. package/src/components/nice-title/nice-title.js +21 -21
  113. package/src/components/nice-toast/nice-toast.html +2 -2
  114. package/src/components/nice-toast/nice-toast.js +56 -56
  115. package/src/components/nice-toast/nice-toast.scss +74 -74
  116. package/src/components/nice-toggle/nice-toggle.html +12 -12
  117. package/src/components/nice-toggle/nice-toggle.js +95 -95
  118. package/src/components/nice-toggle/nice-toggle.scss +74 -67
  119. package/src/components/nice-tooltip/_nice-tooltip.scss +71 -71
  120. package/src/components/nice-tooltip/nice-tooltip.js +23 -23
  121. package/src/components/nice-upload/nice-upload.html +22 -22
  122. package/src/components/nice-upload/nice-upload.js +157 -157
  123. package/src/components/nice-upload/nice-upload.scss +85 -85
  124. package/src/components/nice-wrapper/_nice-wrapper.scss +87 -87
  125. package/src/components/nice-wrapper/nice-wrapper.html +12 -12
  126. package/src/components/nice-wrapper/nice-wrapper.js +43 -43
  127. package/src/components/nice-yesno/nice-yesno.html +14 -14
  128. package/src/components/nice-yesno/nice-yesno.js +109 -109
  129. package/src/components/nice-yesno/nice-yesno.scss +95 -95
  130. package/src/filters/nice-date.js +17 -17
  131. package/src/filters/nice-highlight.js +16 -16
  132. package/src/modals/nice-multilangual-modal/nice-multilangual-modal.html +30 -30
  133. package/src/modals/nice-multilangual-modal/nice-multilangual-modal.js +67 -67
  134. package/src/modals/nice-multilangual-modal/nice-multilangual-modal.scss +19 -19
  135. package/src/nice.js +2 -2
  136. package/src/services/nice-service.js +19 -19
  137. package/src/styles/_bootstrap-variables.scss +178 -178
  138. package/src/styles/_nice-buttons.scss +403 -403
  139. package/src/styles/_nice-common.scss +471 -471
  140. package/src/styles/_nice-ngdialog.scss +85 -85
  141. package/src/styles/_nice-spacing.scss +283 -283
  142. package/src/styles/_nice.scss +67 -65
  143. package/src/styles/_variables.scss +198 -195
@@ -1,286 +1,286 @@
1
- .nice-calendar {
2
- display: block;
3
-
4
- .nice-selected-dates {
5
- padding: 0 10px 5px 10px;
6
- display: flex;
7
-
8
- .nice-start-date,
9
- .nice-end-date {
10
- width: 50%;
11
- color: $nice-font-color;
12
- transition: all 0.3s ease;
13
-
14
- label {
15
- font-size: 9px;
16
- font-weight: normal;
17
- margin: 0;
18
- line-height: 1;
19
- }
20
- }
21
-
22
- .nice-end-date {
23
- text-align: right;
24
- }
25
- }
26
-
27
- .nice-calendar-weeks {
28
- border-bottom: 1px solid $nice-border-color;
29
- }
30
-
31
-
32
- .nice-calendar-time {
33
- display: flex;
34
-
35
- .no-border-right {
36
- .time-picker-minute {
37
- border-right: 0;
38
- }
39
- }
40
-
41
- .time-picker {
42
- position: relative;
43
- width: 20%;
44
- height: 30px;
45
-
46
- &:after {
47
- content: " ";
48
- position: absolute;
49
- top: 50%;
50
- right: 10px;
51
- width: 0;
52
- height: 0;
53
- border-style: solid;
54
- border-width: 4px 4px 0 4px;
55
- margin-top: -2px;
56
- border-color: $nice-border-color transparent transparent transparent;
57
- }
58
- }
59
-
60
- .time-picker-hour,
61
- .time-picker-minute {
62
- width: 100%;
63
- -webkit-appearance: none;
64
- -moz-appearance: none;
65
- appearance: none;
66
- border-radius: 0px;
67
- border: 1px solid $nice-border-color;
68
- border-top: 0;
69
- border-left: 0;
70
- padding: 5px 10px;
71
- background: transparent;
72
- cursor: pointer;
73
- position: relative;
74
- font-size: 14px;
75
- height: 30px;
76
- }
77
-
78
- .time-picker-icon {
79
- border-right: 1px solid $nice-border-color;
80
- width: 20%;
81
- color: $nice-font-color;
82
- border-bottom: 1px solid $nice-border-color;
83
- height: 30px;
84
- display: flex;
85
- justify-content: center;
86
- align-items: center;
87
-
88
- svg {
89
- height: 15px;
90
- width: 15px;
91
- }
92
- }
93
- }
94
-
95
-
96
- .nice-calendar-wrapper {
97
- border-radius: $nice-border-radius;
98
- display: block;
99
- background: white;
100
- width: 100%;
101
- border: solid 1px $nice-border-color;
102
-
103
- $day-width: 14.28571%;
104
- $day-height: 25px;
105
- $spacing: 10px;
106
- $icon-width: 40px;
107
- $header-height: 40px;
108
-
109
- .header {
110
- float: left;
111
- width: 100%;
112
- background: $nice-base-color;
113
- height: $header-height;
114
- line-height: $header-height;
115
- color: white;
116
- display: flex;
117
-
118
- button {
119
- width: $icon-width;
120
- font-size: 1.2em;
121
- font-weight: bold;
122
- position: relative;
123
- line-height: 40px;
124
- padding: 0 $spacing;
125
- flex-shrink: 0;
126
- color: white;
127
- background: transparent;
128
-
129
- &.fa-angle-left {
130
- text-align: left;
131
- }
132
-
133
- &.fa-angle-right {
134
- text-align: right;
135
- margin-left: $icon-width*-1;
136
- }
137
- }
138
-
139
- span {
140
- flex-grow: 1;
141
- text-transform: uppercase;
142
- text-align: center;
143
- color: inherit;
144
- }
145
- }
146
-
147
- .week {
148
- display: flex;
149
- width: 100%;
150
- border-top: solid 1px $nice-border-color;
151
-
152
- &:first-child {
153
- border-top: none;
154
- }
155
-
156
- .day {
157
- position: relative;
158
- width: $day-width;
159
- height: $day-height;
160
- line-height: $day-height;
161
- box-shadow: 0 0 0;
162
- border: 0 none;
163
- border-left: solid 1px $nice-border-color;
164
- font-size: 12px;
165
- text-align: center;
166
- background: white;
167
- color: $nice-font-color;
168
-
169
-
170
- &:first-child {
171
- border-left: none;
172
- }
173
-
174
- &.today:before {
175
- content: " ";
176
- position: absolute;
177
- top: 0;
178
- right: 0;
179
- height: 10px;
180
- width: 10px;
181
- border-style: solid;
182
- border-width: 0 10px 10px 0;
183
- border-color: transparent $nice-base-color transparent transparent;
184
- }
185
-
186
- &.different-month {
187
- color: #C0C0C0;
188
- }
189
-
190
- &.weekend {
191
- background: #fafafa;
192
- }
193
-
194
- &.disabled {
195
- opacity: 0.3;
196
- color: $nice-danger-color;
197
- cursor: not-allowed;
198
- }
199
-
200
- &.selected {
201
- background: lighten($nice-base-color, 30%);
202
- }
203
-
204
- &.start-selected {
205
- background: $nice-base-color;
206
- color: white;
207
- border-bottom-left-radius: 10px;
208
- border-top-left-radius: 10px;
209
- }
210
-
211
- &.end-selected {
212
- background: $nice-base-color;
213
- color: white;
214
- border-bottom-right-radius: 10px;
215
- border-top-right-radius: 10px;
216
- }
217
-
218
- &.selecting-start {
219
- &:hover {
220
- background: lighten($nice-base-color, 3%);
221
- color: white;
222
- border-bottom-left-radius: 10px;
223
- border-top-left-radius: 10px;
224
- }
225
- }
226
-
227
- &.selecting-end {
228
- &:hover {
229
- background: darken($nice-base-color, 10%);
230
- color: white;
231
- border-bottom-right-radius: 10px;
232
- border-top-right-radius: 10px;
233
- }
234
- }
235
-
236
- .popup {
237
- position: relative;
238
- bottom: 45px;
239
- left: 0;
240
- background: #8f8f8f;
241
- color: white;
242
- z-index: 1000;
243
- line-height: 12px;
244
- font-size: 10px;
245
- text-align: left;
246
- padding: 2px 8px;
247
- display: none;
248
- white-space: nowrap;
249
- width: fit-content;
250
- }
251
-
252
- &:hover {
253
- .popup {
254
- display: block;
255
- }
256
- }
257
- }
258
-
259
- &.names>span {
260
- color: darken($nice-base-color, 10%);
261
- line-height: 20px;
262
- height: 20px;
263
- cursor: default;
264
- }
265
- }
266
- }
267
-
268
- .change {
269
- color: $nice-base-color;
270
- }
271
-
272
- .disabled-shield {
273
- position: absolute;
274
- top: 0;
275
- left: 0;
276
- right: 0;
277
- bottom: 0;
278
- z-index: 3;
279
- }
280
-
281
- .disabled {
282
- opacity: 0.5;
283
- cursor: not-allowed;
284
- user-select: none;
285
- }
1
+ .nice-calendar {
2
+ display: block;
3
+
4
+ .nice-selected-dates {
5
+ padding: 0 10px 5px 10px;
6
+ display: flex;
7
+
8
+ .nice-start-date,
9
+ .nice-end-date {
10
+ width: 50%;
11
+ color: $nice-font-color;
12
+ transition: all 0.3s ease;
13
+
14
+ label {
15
+ font-size: 9px;
16
+ font-weight: normal;
17
+ margin: 0;
18
+ line-height: 1;
19
+ }
20
+ }
21
+
22
+ .nice-end-date {
23
+ text-align: right;
24
+ }
25
+ }
26
+
27
+ .nice-calendar-weeks {
28
+ border-bottom: 1px solid $nice-border-color;
29
+ }
30
+
31
+
32
+ .nice-calendar-time {
33
+ display: flex;
34
+
35
+ .no-border-right {
36
+ .time-picker-minute {
37
+ border-right: 0;
38
+ }
39
+ }
40
+
41
+ .time-picker {
42
+ position: relative;
43
+ width: 20%;
44
+ height: 30px;
45
+
46
+ &:after {
47
+ content: " ";
48
+ position: absolute;
49
+ top: 50%;
50
+ right: 10px;
51
+ width: 0;
52
+ height: 0;
53
+ border-style: solid;
54
+ border-width: 4px 4px 0 4px;
55
+ margin-top: -2px;
56
+ border-color: $nice-border-color transparent transparent transparent;
57
+ }
58
+ }
59
+
60
+ .time-picker-hour,
61
+ .time-picker-minute {
62
+ width: 100%;
63
+ -webkit-appearance: none;
64
+ -moz-appearance: none;
65
+ appearance: none;
66
+ border-radius: 0px;
67
+ border: 1px solid $nice-border-color;
68
+ border-top: 0;
69
+ border-left: 0;
70
+ padding: 5px 10px;
71
+ background: transparent;
72
+ cursor: pointer;
73
+ position: relative;
74
+ font-size: 14px;
75
+ height: 30px;
76
+ }
77
+
78
+ .time-picker-icon {
79
+ border-right: 1px solid $nice-border-color;
80
+ width: 20%;
81
+ color: $nice-font-color;
82
+ border-bottom: 1px solid $nice-border-color;
83
+ height: 30px;
84
+ display: flex;
85
+ justify-content: center;
86
+ align-items: center;
87
+
88
+ svg {
89
+ height: 15px;
90
+ width: 15px;
91
+ }
92
+ }
93
+ }
94
+
95
+
96
+ .nice-calendar-wrapper {
97
+ border-radius: $nice-border-radius;
98
+ display: block;
99
+ background: white;
100
+ width: 100%;
101
+ border: solid 1px $nice-border-color;
102
+
103
+ $day-width: 14.28571%;
104
+ $day-height: 25px;
105
+ $spacing: 10px;
106
+ $icon-width: 40px;
107
+ $header-height: 40px;
108
+
109
+ .header {
110
+ float: left;
111
+ width: 100%;
112
+ background: $nice-base-color;
113
+ height: $header-height;
114
+ line-height: $header-height;
115
+ color: white;
116
+ display: flex;
117
+
118
+ button {
119
+ width: $icon-width;
120
+ font-size: 1.2em;
121
+ font-weight: bold;
122
+ position: relative;
123
+ line-height: 40px;
124
+ padding: 0 $spacing;
125
+ flex-shrink: 0;
126
+ color: white;
127
+ background: transparent;
128
+
129
+ &.fa-angle-left {
130
+ text-align: left;
131
+ }
132
+
133
+ &.fa-angle-right {
134
+ text-align: right;
135
+ margin-left: $icon-width*-1;
136
+ }
137
+ }
138
+
139
+ span {
140
+ flex-grow: 1;
141
+ text-transform: uppercase;
142
+ text-align: center;
143
+ color: inherit;
144
+ }
145
+ }
146
+
147
+ .week {
148
+ display: flex;
149
+ width: 100%;
150
+ border-top: solid 1px $nice-border-color;
151
+
152
+ &:first-child {
153
+ border-top: none;
154
+ }
155
+
156
+ .day {
157
+ position: relative;
158
+ width: $day-width;
159
+ height: $day-height;
160
+ line-height: $day-height;
161
+ box-shadow: 0 0 0;
162
+ border: 0 none;
163
+ border-left: solid 1px $nice-border-color;
164
+ font-size: 12px;
165
+ text-align: center;
166
+ background: white;
167
+ color: $nice-font-color;
168
+
169
+
170
+ &:first-child {
171
+ border-left: none;
172
+ }
173
+
174
+ &.today:before {
175
+ content: " ";
176
+ position: absolute;
177
+ top: 0;
178
+ right: 0;
179
+ height: 10px;
180
+ width: 10px;
181
+ border-style: solid;
182
+ border-width: 0 10px 10px 0;
183
+ border-color: transparent $nice-base-color transparent transparent;
184
+ }
185
+
186
+ &.different-month {
187
+ color: #C0C0C0;
188
+ }
189
+
190
+ &.weekend {
191
+ background: #fafafa;
192
+ }
193
+
194
+ &.disabled {
195
+ opacity: 0.3;
196
+ color: $nice-danger-color;
197
+ cursor: not-allowed;
198
+ }
199
+
200
+ &.selected {
201
+ background: lighten($nice-base-color, 30%);
202
+ }
203
+
204
+ &.start-selected {
205
+ background: $nice-base-color;
206
+ color: white;
207
+ border-bottom-left-radius: 10px;
208
+ border-top-left-radius: 10px;
209
+ }
210
+
211
+ &.end-selected {
212
+ background: $nice-base-color;
213
+ color: white;
214
+ border-bottom-right-radius: 10px;
215
+ border-top-right-radius: 10px;
216
+ }
217
+
218
+ &.selecting-start {
219
+ &:hover {
220
+ background: lighten($nice-base-color, 3%);
221
+ color: white;
222
+ border-bottom-left-radius: 10px;
223
+ border-top-left-radius: 10px;
224
+ }
225
+ }
226
+
227
+ &.selecting-end {
228
+ &:hover {
229
+ background: darken($nice-base-color, 10%);
230
+ color: white;
231
+ border-bottom-right-radius: 10px;
232
+ border-top-right-radius: 10px;
233
+ }
234
+ }
235
+
236
+ .popup {
237
+ position: relative;
238
+ bottom: 45px;
239
+ left: 0;
240
+ background: #8f8f8f;
241
+ color: white;
242
+ z-index: 1000;
243
+ line-height: 12px;
244
+ font-size: 10px;
245
+ text-align: left;
246
+ padding: 2px 8px;
247
+ display: none;
248
+ white-space: nowrap;
249
+ width: fit-content;
250
+ }
251
+
252
+ &:hover {
253
+ .popup {
254
+ display: block;
255
+ }
256
+ }
257
+ }
258
+
259
+ &.names>span {
260
+ color: darken($nice-base-color, 10%);
261
+ line-height: 20px;
262
+ height: 20px;
263
+ cursor: default;
264
+ }
265
+ }
266
+ }
267
+
268
+ .change {
269
+ color: $nice-base-color;
270
+ }
271
+
272
+ .disabled-shield {
273
+ position: absolute;
274
+ top: 0;
275
+ left: 0;
276
+ right: 0;
277
+ bottom: 0;
278
+ z-index: 3;
279
+ }
280
+
281
+ .disabled {
282
+ opacity: 0.5;
283
+ cursor: not-allowed;
284
+ user-select: none;
285
+ }
286
286
  }
@@ -1,6 +1,6 @@
1
- <div class="nice-component nice-checkbox" ng-class="{ 'nice-checkbox-checked': model, 'margin-bottom-0' : noMargin, 'nice-checkbox-disabled': isDisabled, 'nice-checkbox-left': titleOnLeft }" ng-click="toggle()">
2
- <button type="button" class="btn nice-checkbox-checkbox" ng-disabled="isDisabled">
3
- <nice-icon class="nice-checkbox-check" icon="icon-check"></nice-icon>
4
- </button>
5
- <div ng-if="title" class="nice-checkbox-message" ng-class="{ 'nice-disabled': isDisabled }">{{ title }}</div>
1
+ <div class="nice-component nice-checkbox" ng-class="{ 'nice-checkbox-checked': model, 'margin-bottom-0' : noMargin, 'nice-checkbox-disabled': isDisabled, 'nice-checkbox-left': titleOnLeft }" ng-click="toggle()">
2
+ <button type="button" class="btn nice-checkbox-checkbox" ng-disabled="isDisabled">
3
+ <nice-icon class="nice-checkbox-check" icon="icon-check"></nice-icon>
4
+ </button>
5
+ <div ng-if="title" class="nice-checkbox-message" ng-class="{ 'nice-disabled': isDisabled }">{{ title }}</div>
6
6
  </div>
@@ -1,33 +1,33 @@
1
- 'use strict';
2
-
3
- /**
4
- * @ngdoc directive
5
- * @name niceElements.directive:niceCheckbox
6
- * @description
7
- * # niceCheckbox
8
- */
9
- angular.module('niceElements')
10
- .directive('niceCheckbox', function () {
11
- return {
12
- templateUrl: 'src/components/nice-checkbox/nice-checkbox.html',
13
- restrict: 'E',
14
- scope: {
15
- model: '=',
16
- title: '@',
17
- titleOnLeft: '=',
18
- noMargin: '@',
19
- clickDisabled: '@',
20
- onChange: '&?',
21
- isDisabled: '=',
22
- },
23
- controller: function ($scope) {
24
- if ($scope.model === undefined) $scope.model = false;
25
-
26
- $scope.toggle = function () {
27
- if ($scope.isDisabled || $scope.clickDisabled) return;
28
- $scope.model = !$scope.model;
29
- if ($scope.onChange) $scope.onChange({ model: $scope.model });
30
- };
31
- }
32
- };
33
- });
1
+ 'use strict';
2
+
3
+ /**
4
+ * @ngdoc directive
5
+ * @name niceElements.directive:niceCheckbox
6
+ * @description
7
+ * # niceCheckbox
8
+ */
9
+ angular.module('niceElements')
10
+ .directive('niceCheckbox', function () {
11
+ return {
12
+ templateUrl: 'src/components/nice-checkbox/nice-checkbox.html',
13
+ restrict: 'E',
14
+ scope: {
15
+ model: '=',
16
+ title: '@',
17
+ titleOnLeft: '=',
18
+ noMargin: '@',
19
+ clickDisabled: '@',
20
+ onChange: '&?',
21
+ isDisabled: '=',
22
+ },
23
+ controller: function ($scope) {
24
+ if ($scope.model === undefined) $scope.model = false;
25
+
26
+ $scope.toggle = function () {
27
+ if ($scope.isDisabled || $scope.clickDisabled) return;
28
+ $scope.model = !$scope.model;
29
+ if ($scope.onChange) $scope.onChange({ model: $scope.model });
30
+ };
31
+ }
32
+ };
33
+ });