Skip to content

Commit 341d192

Browse files
committed
Release 1.6.0
1 parent 3ebf28c commit 341d192

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

56 files changed

+947
-183
lines changed

CHANGELOG.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,26 @@
1+
## 1.6.0 (27.12.2021)
2+
3+
### Dependencies:
4+
5+
- Updated Bootstrap to 5.1.3 version.
6+
7+
### Fixes and improvements:
8+
9+
- Charts - resolved problem with `chartjs-plugin-datalabels` configuration,
10+
- Carousel - component should now work correctly inside components with `OnPush` change detection strategy,
11+
- Table - updated `dataSource` type to resolve problem with asynchronous data and async pipe,
12+
- File upload plugin - resolved problem with extensions handled by the `acceptedExtensions` input,
13+
- Popconfirm - target element will be now optional in modal display mode,
14+
- Sidenav - resolved problem with `child.querySelector is not a function` error when using `ngFor` directive to render sidenav items,
15+
- Popover - `mdbPopover` input will now correctly accept value with `TemplateRef` type.
16+
17+
### New:
18+
19+
- Dropdown - added new `closeOnOutsideClick`, `closeOnItemClick`, `closeOnEsc` inputs that allow to configure menu closing actions,
20+
- File upload plugin - added a new `reset` method that allow to reset component state to default settings.
21+
22+
---
23+
124
## 1.5.1 (22.11.2021)
225

326
### Fixes and improvements

README.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
MDB 5 Angular
22

3-
Version: FREE 1.5.0
3+
Version: FREE 1.6.0
44

55
Documentation:
66
https://mdbootstrap.com/docs/b5/angular/

package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "mdb-angular-ui-kit-free",
3-
"version": "1.5.1",
3+
"version": "1.6.0",
44
"scripts": {
55
"ng": "ng",
66
"start": "ng serve",

projects/mdb-angular-ui-kit/CHANGELOG.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,26 @@
1+
## 1.6.0 (27.12.2021)
2+
3+
### Dependencies:
4+
5+
- Updated Bootstrap to 5.1.3 version.
6+
7+
### Fixes and improvements:
8+
9+
- Charts - resolved problem with `chartjs-plugin-datalabels` configuration,
10+
- Carousel - component should now work correctly inside components with `OnPush` change detection strategy,
11+
- Table - updated `dataSource` type to resolve problem with asynchronous data and async pipe,
12+
- File upload plugin - resolved problem with extensions handled by the `acceptedExtensions` input,
13+
- Popconfirm - target element will be now optional in modal display mode,
14+
- Sidenav - resolved problem with `child.querySelector is not a function` error when using `ngFor` directive to render sidenav items,
15+
- Popover - `mdbPopover` input will now correctly accept value with `TemplateRef` type.
16+
17+
### New:
18+
19+
- Dropdown - added new `closeOnOutsideClick`, `closeOnItemClick`, `closeOnEsc` inputs that allow to configure menu closing actions,
20+
- File upload plugin - added a new `reset` method that allow to reset component state to default settings.
21+
22+
---
23+
124
## 1.5.1 (22.11.2021)
225

326
### Fixes and improvements

projects/mdb-angular-ui-kit/assets/scss/bootstrap/_card.scss

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
background-clip: border-box;
1414
border: $card-border-width solid $card-border-color;
1515
@include border-radius($card-border-radius);
16+
@include box-shadow($card-box-shadow);
1617

1718
> hr {
1819
margin-right: 0;
@@ -55,7 +56,7 @@
5556
}
5657

5758
.card-subtitle {
58-
margin-top: -$card-title-spacer-y / 2;
59+
margin-top: -$card-title-spacer-y * 0.5;
5960
margin-bottom: 0;
6061
}
6162

@@ -65,7 +66,7 @@
6566

6667
.card-link {
6768
&:hover {
68-
text-decoration: none;
69+
text-decoration: if($link-hover-decoration == underline, none, null);
6970
}
7071

7172
+ .card-link {
@@ -105,9 +106,9 @@
105106
//
106107

107108
.card-header-tabs {
108-
margin-right: -$card-cap-padding-x / 2;
109+
margin-right: -$card-cap-padding-x * 0.5;
109110
margin-bottom: -$card-cap-padding-y;
110-
margin-left: -$card-cap-padding-x / 2;
111+
margin-left: -$card-cap-padding-x * 0.5;
111112
border-bottom: 0;
112113

113114
@if $nav-tabs-link-active-bg != $card-bg {
@@ -119,8 +120,8 @@
119120
}
120121

121122
.card-header-pills {
122-
margin-right: -$card-cap-padding-x / 2;
123-
margin-left: -$card-cap-padding-x / 2;
123+
margin-right: -$card-cap-padding-x * 0.5;
124+
margin-left: -$card-cap-padding-x * 0.5;
124125
}
125126

126127
// Card image

projects/mdb-angular-ui-kit/assets/scss/bootstrap/_carousel.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -207,9 +207,9 @@
207207

208208
.carousel-caption {
209209
position: absolute;
210-
right: (100% - $carousel-caption-width) / 2;
210+
right: (100% - $carousel-caption-width) * 0.5;
211211
bottom: $carousel-caption-spacer;
212-
left: (100% - $carousel-caption-width) / 2;
212+
left: (100% - $carousel-caption-width) * 0.5;
213213
padding-top: $carousel-caption-padding-y;
214214
padding-bottom: $carousel-caption-padding-y;
215215
color: $carousel-caption-color;

projects/mdb-angular-ui-kit/assets/scss/bootstrap/_dropdown.scss

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -50,17 +50,17 @@
5050
--bs-position: start;
5151

5252
&[data-bs-popper] {
53-
right: auto #{'/* rtl:ignore */'};
54-
left: 0 #{'/* rtl:ignore */'};
53+
right: auto;
54+
left: 0;
5555
}
5656
}
5757

5858
.dropdown-menu#{$infix}-end {
5959
--bs-position: end;
6060

6161
&[data-bs-popper] {
62-
right: 0 #{'/* rtl:ignore */'};
63-
left: auto #{'/* rtl:ignore */'};
62+
right: 0;
63+
left: auto;
6464
}
6565
}
6666
}

projects/mdb-angular-ui-kit/assets/scss/bootstrap/_functions.scss

Lines changed: 119 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,62 @@
3232
}
3333
}
3434

35+
// Colors
36+
@function to-rgb($value) {
37+
@return red($value), green($value), blue($value);
38+
}
39+
40+
// stylelint-disable scss/dollar-variable-pattern
41+
@function rgba-css-var($identifier, $target) {
42+
@if $identifier == 'body' and $target == 'bg' {
43+
@return rgba(
44+
var(--#{$variable-prefix}#{$identifier}-bg-rgb),
45+
var(--#{$variable-prefix}#{$target}-opacity)
46+
);
47+
}
48+
@if $identifier == 'body' and $target == 'text' {
49+
@return rgba(
50+
var(--#{$variable-prefix}#{$identifier}-color-rgb),
51+
var(--#{$variable-prefix}#{$target}-opacity)
52+
);
53+
} @else {
54+
@return rgba(
55+
var(--#{$variable-prefix}#{$identifier}-rgb),
56+
var(--#{$variable-prefix}#{$target}-opacity)
57+
);
58+
}
59+
}
60+
61+
@function map-loop($map, $func, $args...) {
62+
$_map: ();
63+
64+
@each $key, $value in $map {
65+
// allow to pass the $key and $value of the map as an function argument
66+
$_args: ();
67+
@each $arg in $args {
68+
$_args: append($_args, if($arg == '$key', $key, if($arg == '$value', $value, $arg)));
69+
}
70+
71+
$_map: map-merge(
72+
$_map,
73+
(
74+
$key: call(get-function($func), $_args...),
75+
)
76+
);
77+
}
78+
79+
@return $_map;
80+
}
81+
// stylelint-enable scss/dollar-variable-pattern
82+
83+
@function varify($list) {
84+
$result: null;
85+
@each $entry in $list {
86+
$result: append($result, var(--#{$variable-prefix}#{$entry}), space);
87+
}
88+
@return $result;
89+
}
90+
3591
// Internal Bootstrap function to turn maps into its negative variant.
3692
// It prefixes the keys with `n` and makes the value negative.
3793
@function negativify-map($map) {
@@ -60,6 +116,16 @@
60116
@return $result;
61117
}
62118

119+
// Merge multiple maps
120+
@function map-merge-multiple($maps...) {
121+
$merged-maps: ();
122+
123+
@each $map in $maps {
124+
$merged-maps: map-merge($merged-maps, $map);
125+
}
126+
@return $merged-maps;
127+
}
128+
63129
// Replace `$search` with `$replace` in `$string`
64130
// Used on our SVG icon backgrounds for custom forms.
65131
//
@@ -101,7 +167,7 @@
101167
// Color contrast
102168
// See https://github.com/twbs/bootstrap/pull/30168
103169

104-
// A list of pre-calculated numbers of pow(($value / 255 + .055) / 1.055, 2.4). (from 0 to 255)
170+
// A list of pre-calculated numbers of pow(divide((divide($value, 255) + .055), 1.055), 2.4). (from 0 to 255)
105171
// stylelint-disable-next-line scss/dollar-variable-default, scss/dollar-variable-pattern
106172
$_luminance-list: 0.0008 0.001 0.0011 0.0013 0.0015 0.0017 0.002 0.0022 0.0025 0.0027 0.003 0.0033
107173
0.0037 0.004 0.0044 0.0048 0.0052 0.0056 0.006 0.0065 0.007 0.0075 0.008 0.0086 0.0091 0.0097
@@ -152,7 +218,7 @@ $_luminance-list: 0.0008 0.001 0.0011 0.0013 0.0015 0.0017 0.002 0.0022 0.0025 0
152218
$l1: luminance($background);
153219
$l2: luminance(opaque($background, $foreground));
154220

155-
@return if($l1 > $l2, ($l1 + 0.05) / ($l2 + 0.05), ($l2 + 0.05) / ($l1 + 0.05));
221+
@return if($l1 > $l2, divide($l1 + 0.05, $l2 + 0.05), divide($l2 + 0.05, $l1 + 0.05));
156222
}
157223

158224
// Return WCAG2.0 relative luminance
@@ -166,7 +232,11 @@ $_luminance-list: 0.0008 0.001 0.0011 0.0013 0.0015 0.0017 0.002 0.0022 0.0025 0
166232
);
167233

168234
@each $name, $value in $rgb {
169-
$value: if($value / 255 < 0.03928, $value / 255 / 12.92, nth($_luminance-list, $value + 1));
235+
$value: if(
236+
divide($value, 255) < 0.03928,
237+
divide(divide($value, 255), 12.92),
238+
nth($_luminance-list, $value + 1)
239+
);
170240
$rgb: map-merge(
171241
$rgb,
172242
(
@@ -240,9 +310,55 @@ $_luminance-list: 0.0008 0.001 0.0011 0.0013 0.0015 0.0017 0.002 0.0022 0.0025 0
240310
@return $value1 - $value2;
241311
}
242312

313+
@if type-of($value2) != number {
314+
$value2: unquote('(') + $value2 + unquote(')');
315+
}
316+
243317
@return if(
244318
$return-calc == true,
245319
calc(#{$value1} - #{$value2}),
246320
$value1 + unquote(' - ') + $value2
247321
);
248322
}
323+
324+
@function divide($dividend, $divisor, $precision: 10) {
325+
$sign: if($dividend > 0 and $divisor > 0 or $dividend < 0 and $divisor < 0, 1, -1);
326+
$dividend: abs($dividend);
327+
$divisor: abs($divisor);
328+
@if $dividend == 0 {
329+
@return 0;
330+
}
331+
@if $divisor == 0 {
332+
@error "Cannot divide by 0";
333+
}
334+
$remainder: $dividend;
335+
$result: 0;
336+
$factor: 10;
337+
@while ($remainder > 0 and $precision >= 0) {
338+
$quotient: 0;
339+
@while ($remainder >= $divisor) {
340+
$remainder: $remainder - $divisor;
341+
$quotient: $quotient + 1;
342+
}
343+
$result: $result * 10 + $quotient;
344+
$factor: $factor * 0.1;
345+
$remainder: $remainder * 10;
346+
$precision: $precision - 1;
347+
@if ($precision < 0 and $remainder >= $divisor * 5) {
348+
$result: $result + 1;
349+
}
350+
}
351+
$result: $result * $factor * $sign;
352+
$dividend-unit: unit($dividend);
353+
$divisor-unit: unit($divisor);
354+
$unit-map: (
355+
'px': 1px,
356+
'rem': 1rem,
357+
'em': 1em,
358+
'%': 1%,
359+
);
360+
@if ($dividend-unit != $divisor-unit and map-has-key($unit-map, $dividend-unit)) {
361+
$result: $result * map-get($unit-map, $dividend-unit);
362+
}
363+
@return $result;
364+
}

projects/mdb-angular-ui-kit/assets/scss/bootstrap/_grid.scss

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,17 @@
1212
}
1313
}
1414

15+
@if $enable-cssgrid {
16+
.grid {
17+
display: grid;
18+
grid-template-rows: repeat(var(--#{$variable-prefix}rows, 1), 1fr);
19+
grid-template-columns: repeat(var(--#{$variable-prefix}columns, #{$grid-columns}), 1fr);
20+
gap: var(--#{$variable-prefix}gap, #{$grid-gutter-width});
21+
22+
@include make-cssgrid();
23+
}
24+
}
25+
1526
// Columns
1627
//
1728
// Common styles for small and large grid columns

projects/mdb-angular-ui-kit/assets/scss/bootstrap/_helpers.scss

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
@import 'helpers/colored-links';
33
@import 'helpers/ratio';
44
@import 'helpers/position';
5+
@import 'helpers/stacks';
56
@import 'helpers/visually-hidden';
67
@import 'helpers/stretched-link';
78
@import 'helpers/text-truncation';
9+
@import 'helpers/vr';

projects/mdb-angular-ui-kit/assets/scss/bootstrap/_images.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
}
3232

3333
.figure-img {
34-
margin-bottom: $spacer / 2;
34+
margin-bottom: $spacer * 0.5;
3535
line-height: 1;
3636
}
3737

projects/mdb-angular-ui-kit/assets/scss/bootstrap/_mixins.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222

2323
// Components
2424
@import 'mixins/alert';
25+
@import 'mixins/backdrop';
2526
@import 'mixins/buttons';
2627
@import 'mixins/caret';
2728
@import 'mixins/pagination';

0 commit comments

Comments
 (0)