@itwin/itwinui-css 0.50.1 → 0.53.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 (89) hide show
  1. package/css/alert.css +234 -176
  2. package/css/all.css +8324 -5880
  3. package/css/badge.css +3 -2
  4. package/css/blockquote.css +12 -9
  5. package/css/breadcrumbs.css +110 -87
  6. package/css/button.css +441 -345
  7. package/css/carousel.css +110 -91
  8. package/css/code.css +70 -57
  9. package/css/color-picker.css +164 -113
  10. package/css/date-picker.css +454 -80
  11. package/css/expandable-block.css +213 -161
  12. package/css/fieldset.css +25 -21
  13. package/css/file-upload.css +93 -79
  14. package/css/footer.css +64 -53
  15. package/css/global.css +550 -197
  16. package/css/header.css +485 -367
  17. package/css/icon.css +108 -78
  18. package/css/information-panel.css +181 -137
  19. package/css/inputs.css +1137 -945
  20. package/css/keyboard.css +14 -10
  21. package/css/location-marker.css +69 -59
  22. package/css/menu.css +124 -86
  23. package/css/modal.css +114 -44
  24. package/css/non-ideal-state.css +47 -40
  25. package/css/notification-marker.css +275 -200
  26. package/css/popover.css +10 -8
  27. package/css/progress-indicator.css +316 -238
  28. package/css/reset-global-styles.css +10 -5
  29. package/css/side-navigation.css +193 -144
  30. package/css/skip-to-content.css +42 -28
  31. package/css/slider.css +116 -91
  32. package/css/surface.css +19 -0
  33. package/css/table.css +578 -430
  34. package/css/tabs.css +324 -238
  35. package/css/tag.css +112 -85
  36. package/css/text.css +47 -28
  37. package/css/tile.css +389 -313
  38. package/css/time-picker.css +114 -87
  39. package/css/toast-notification.css +234 -175
  40. package/css/toggle-switch.css +176 -111
  41. package/css/tooltip.css +24 -17
  42. package/css/tree.css +123 -93
  43. package/css/user-icon.css +222 -162
  44. package/css/wizard.css +158 -133
  45. package/package.json +5 -6
  46. package/scss/alert/alert.scss +1 -5
  47. package/scss/carousel/carousel.scss +24 -27
  48. package/scss/classes.scss +1 -0
  49. package/scss/code/codeblock.scss +1 -1
  50. package/scss/color-picker/color-picker.scss +2 -2
  51. package/scss/date-picker/classes.scss +20 -0
  52. package/scss/date-picker/date-picker.scss +194 -33
  53. package/scss/fieldset/fieldset.scss +1 -1
  54. package/scss/header/header.scss +15 -10
  55. package/scss/index.scss +1 -0
  56. package/scss/information-panel/information-panel.scss +10 -3
  57. package/scss/inputs/checkbox.scss +1 -0
  58. package/scss/inputs/labeled-inputs.scss +8 -8
  59. package/scss/inputs/radio.scss +0 -4
  60. package/scss/location-marker/data-rich.scss +1 -1
  61. package/scss/location-marker/me.scss +4 -4
  62. package/scss/menu/classes.scss +2 -1
  63. package/scss/menu/menu.scss +8 -11
  64. package/scss/modal/classes.scss +4 -0
  65. package/scss/modal/modal.scss +82 -7
  66. package/scss/popover/popover.scss +1 -2
  67. package/scss/progress-indicator/linear.scss +3 -11
  68. package/scss/progress-indicator/radial.scss +1 -1
  69. package/scss/side-navigation/side-navigation.scss +5 -5
  70. package/scss/slider/slider.scss +2 -2
  71. package/scss/style/elevation.scss +5 -5
  72. package/scss/style/global.scss +33 -26
  73. package/scss/style/mixins.scss +9 -0
  74. package/scss/style/ripple.scss +1 -1
  75. package/scss/style/speed.scss +1 -0
  76. package/scss/style/theme.scss +248 -65
  77. package/scss/surface/classes.scss +7 -0
  78. package/scss/surface/index.scss +3 -0
  79. package/scss/surface/surface.scss +18 -0
  80. package/scss/table/column-filter.scss +2 -2
  81. package/scss/table/table.scss +26 -17
  82. package/scss/tile/tile.scss +5 -5
  83. package/scss/time-picker/time-picker.scss +2 -2
  84. package/scss/toast-notification/categories.scss +1 -5
  85. package/scss/toggle-switch/classes.scss +4 -0
  86. package/scss/toggle-switch/toggle-switch.scss +141 -162
  87. package/scss/tooltip/tooltip.scss +2 -1
  88. package/scss/user-icon/user-icon.scss +38 -19
  89. package/scss/wizard/wizard.scss +1 -1
@@ -1,10 +1,10 @@
1
+ /* stylelint-disable selector-class-pattern */
1
2
  // Copyright (c) Bentley Systems, Incorporated. All rights reserved.
2
3
  // See LICENSE.md in the project root for license terms and full copyright notice.
3
4
  @import '../style/index';
4
5
 
5
6
  // tippy.js helper class to hide Popover when it is scrolled out of view
6
7
  @mixin iui-popover {
7
- /* stylelint-disable-next-line selector-class-pattern */
8
8
  &.tippy-box {
9
9
  &[data-reference-hidden] {
10
10
  visibility: visible;
@@ -16,7 +16,6 @@
16
16
  }
17
17
 
18
18
  // Resets tippy.js default stylings that interfere with our own
19
- /* stylelint-disable-next-line selector-class-pattern */
20
19
  .tippy-content {
21
20
  all: revert;
22
21
  }
@@ -13,7 +13,7 @@
13
13
  overflow: hidden;
14
14
 
15
15
  @include themed {
16
- background-color: t(iui-color-background-5);
16
+ background-color: t(iui-color-background-border);
17
17
  }
18
18
 
19
19
  > .iui-fill {
@@ -71,11 +71,7 @@
71
71
  }
72
72
 
73
73
  > span {
74
- &::selection {
75
- @include themed {
76
- background-color: rgba(t(iui-color-foreground-positive-rgb), t(iui-opacity-4));
77
- }
78
- }
74
+ @include iui-text-selection(positive);
79
75
  }
80
76
  }
81
77
  }
@@ -101,11 +97,7 @@
101
97
  }
102
98
 
103
99
  > span {
104
- &::selection {
105
- @include themed {
106
- background-color: rgba(t(iui-color-foreground-negative-rgb), t(iui-opacity-4));
107
- }
108
- }
100
+ @include iui-text-selection(negative);
109
101
  }
110
102
  }
111
103
  }
@@ -27,7 +27,7 @@
27
27
  animation: dash $iui-speed-slow linear infinite;
28
28
 
29
29
  @include themed {
30
- border-bottom-color: t(iui-color-background-5);
30
+ border-bottom-color: t(iui-color-background-border);
31
31
  }
32
32
  }
33
33
 
@@ -14,7 +14,7 @@
14
14
  }
15
15
  @include themed {
16
16
  background-color: t(iui-color-background-3);
17
- border-right: 1px solid t(iui-color-background-5);
17
+ border-right: 1px solid t(iui-color-background-border);
18
18
  }
19
19
 
20
20
  > .iui-sidenav-content {
@@ -51,7 +51,7 @@
51
51
  + .iui-sidenav-button.iui-expand {
52
52
  border: none;
53
53
  @include themed {
54
- border-top: 1px solid t(iui-color-background-5);
54
+ border-top: 1px solid t(iui-color-background-border);
55
55
  }
56
56
  }
57
57
  }
@@ -105,7 +105,7 @@
105
105
  &:hover,
106
106
  &[disabled] {
107
107
  @include themed {
108
- border-color: t(iui-color-background-5);
108
+ border-color: t(iui-color-background-border);
109
109
  }
110
110
  }
111
111
 
@@ -133,7 +133,7 @@
133
133
  justify-content: center;
134
134
  border: none;
135
135
  @include themed {
136
- border-bottom: 1px solid t(iui-color-background-5);
136
+ border-bottom: 1px solid t(iui-color-background-border);
137
137
  }
138
138
 
139
139
  > .iui-button-icon {
@@ -157,7 +157,7 @@
157
157
  resize: horizontal;
158
158
  @include themed {
159
159
  background-color: t(iui-color-background-1);
160
- border-right: 1px solid t(iui-color-background-5);
160
+ border-right: 1px solid t(iui-color-background-border);
161
161
  }
162
162
 
163
163
  @include iui-transition-group;
@@ -53,7 +53,7 @@ $tick-height: $iui-baseline; // 11px
53
53
  height: $track-height;
54
54
  top: $iui-sm;
55
55
  @include themed {
56
- background-color: t(iui-color-background-4);
56
+ background-color: t(iui-color-background-border);
57
57
  }
58
58
  }
59
59
 
@@ -71,7 +71,7 @@ $tick-height: $iui-baseline; // 11px
71
71
  @include iui-focus($thickness: 2px);
72
72
  @include themed {
73
73
  background: t(iui-color-background-1);
74
- border: 1px solid t(iui-color-background-5);
74
+ border: 1px solid t(iui-color-background-border);
75
75
  }
76
76
 
77
77
  &:active {
@@ -3,8 +3,8 @@
3
3
  /// Elevations:
4
4
 
5
5
  $iui-elevation-0: 0;
6
- $iui-elevation-2: 0 1px 5px rgba(0, 0, 0, 0.25);
7
- $iui-elevation-4: 0 1px 10px rgba(0, 0, 0, 0.25);
8
- $iui-elevation-8: 0 3px 14px rgba(0, 0, 0, 0.25);
9
- $iui-elevation-16: 0 6px 30px rgba(0, 0, 0, 0.25);
10
- $iui-elevation-24: 0 9px 46px rgba(0, 0, 0, 0.25);
6
+ $iui-elevation-2: 0 1px 5px hsla(200, 12%, 0%, 0.25);
7
+ $iui-elevation-4: 0 1px 10px hsla(200, 12%, 0%, 0.25);
8
+ $iui-elevation-8: 0 3px 14px hsla(200, 12%, 0%, 0.25);
9
+ $iui-elevation-16: 0 6px 30px hsla(200, 12%, 0%, 0.25);
10
+ $iui-elevation-24: 0 9px 46px hsla(200, 12%, 0%, 0.25);
@@ -2,6 +2,38 @@
2
2
  // See LICENSE.md in the project root for license terms and full copyright notice.
3
3
  @import './index';
4
4
 
5
+ html {
6
+ @include theme-variables(light);
7
+
8
+ @media (prefers-color-scheme: dark) {
9
+ @include theme-variables(dark);
10
+ }
11
+
12
+ @media (prefers-color-scheme: light) and (prefers-contrast: more) {
13
+ @include theme-variables(light-hc);
14
+ }
15
+
16
+ @media (prefers-color-scheme: dark) and (prefers-contrast: more) {
17
+ @include theme-variables(dark-hc);
18
+ }
19
+
20
+ &.iui-theme-light {
21
+ @include theme-variables(light);
22
+ }
23
+
24
+ &.iui-theme-dark {
25
+ @include theme-variables(dark);
26
+ }
27
+
28
+ &.iui-theme-light-hc {
29
+ @include theme-variables(light-hc);
30
+ }
31
+
32
+ &.iui-theme-dark-hc {
33
+ @include theme-variables(dark-hc);
34
+ }
35
+ }
36
+
5
37
  .iui-body {
6
38
  @include themed {
7
39
  background-color: t(iui-color-background-2);
@@ -26,33 +58,8 @@
26
58
  [class*='iui-'],
27
59
  [class*='iui-'] * {
28
60
  // Text highlight
29
- ::selection {
30
- @include themed {
31
- background-color: rgba(t(iui-color-foreground-primary-rgb), t(iui-opacity-4));
32
- }
33
- }
61
+ @include iui-text-selection;
34
62
 
35
63
  // Scrollbar
36
64
  @include iui-scrollbar;
37
65
  }
38
-
39
- html {
40
- &,
41
- &.iui-theme-light {
42
- @include theme-variables(light);
43
- }
44
-
45
- &.iui-theme-dark {
46
- @include theme-variables(dark);
47
- }
48
-
49
- @media (prefers-color-scheme: light) {
50
- // fall back to default - light theme variables
51
- }
52
-
53
- @media (prefers-color-scheme: dark) {
54
- &:not([class*='iui-theme-']) {
55
- @include theme-variables(dark);
56
- }
57
- }
58
- }
@@ -63,6 +63,15 @@
63
63
  }
64
64
  }
65
65
 
66
+ @mixin iui-text-selection($status: primary) {
67
+ &::selection,
68
+ *::selection {
69
+ @include themed {
70
+ background-color: rgba(t(iui-color-foreground-#{$status}-rgb), t(iui-opacity-5));
71
+ }
72
+ }
73
+ }
74
+
66
75
  @mixin iui-scrollbar {
67
76
  @include themed {
68
77
  scrollbar-color: rgba(t(iui-color-foreground-body-rgb), t(iui-opacity-4)) transparent;
@@ -13,6 +13,6 @@
13
13
  &:active {
14
14
  background-color: $rippleColor;
15
15
  background-size: 100%;
16
- transition: background 0s;
16
+ transition: background $iui-speed-instant;
17
17
  }
18
18
  }
@@ -2,6 +2,7 @@
2
2
  // See LICENSE.md in the project root for license terms and full copyright notice.
3
3
  /// Animation speed:
4
4
 
5
+ $iui-speed-instant: 0s;
5
6
  $iui-speed-fast: 0.2s;
6
7
  $iui-speed: 0.4s;
7
8
  $iui-speed-slow: 0.8s;