@ulu/frontend 0.1.0-beta.69 → 0.1.0-beta.70

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ulu/frontend",
3
- "version": "0.1.0-beta.69",
3
+ "version": "0.1.0-beta.70",
4
4
  "description": "A versatile SCSS and JavaScript component library offering configurable, accessible components and flexible integration into any project, with SCSS modules suitable for modern JS frameworks.",
5
5
  "browser": "js/index.js",
6
6
  "main": "index.js",
package/scss/_color.scss CHANGED
@@ -23,7 +23,7 @@ $palette: (
23
23
  "type-tertiary" : rgb(157, 157, 157),
24
24
  "headline" : inherit,
25
25
  "background" : white,
26
- "background-gray" : #F7F8F7,
26
+ "background-gray" : #fafafa,
27
27
  "focus" : blue,
28
28
  "accent" : orange,
29
29
  "info" : #00bde3,
@@ -46,10 +46,10 @@ $palette: (
46
46
  "bullet" : inherit,
47
47
  "control" : white,
48
48
  "control-hover" : white,
49
- "control-active" : white,
49
+ "control-active" : white,
50
50
  "control-border" : purple,
51
- "control-border-hover" : blue,
52
- "control-border-active" : orange,
51
+ "control-border-hover" : blue,
52
+ "control-border-active" : orange,
53
53
  "control-background" : purple,
54
54
  "control-background-hover": blue,
55
55
  "control-background-active": orange,
@@ -41,11 +41,12 @@
41
41
  /// @prop {Dimension} summary-type-size [false] The size of the text in the accordion summary.
42
42
  /// @prop {Dimension} transparent-padding-y [1em] The upper and lower padding of the transparent summary.
43
43
  /// @prop {Dimension} transparent-padding-x [0] The upper and lower padding of the transparent summary.
44
+ /// @prop {Dimension} borderless-margin-between [0.5rem] Margin between accordions when using no-border modiifier
44
45
 
45
46
  $config: (
46
47
  "background-color": "background",
47
- "background-color-open": "background-gray",
48
- "border-color": "rule",
48
+ "background-color-open": white,
49
+ "border-color": "rule-light",
49
50
  "border-radius": 0,
50
51
  "border-width": 1px,
51
52
  "box-shadow": none,
@@ -61,7 +62,7 @@ $config: (
61
62
  "icon-font-size": 1.5rem,
62
63
  "icon-size": auto,
63
64
  "icon-stroke-width": 0.15em,
64
- "summary-background-color": "white",
65
+ "summary-background-color": #f6f6f6,
65
66
  "summary-color": null,
66
67
  "summary-background-color-hover": null,
67
68
  "summary-color-hover": null,
@@ -70,6 +71,7 @@ $config: (
70
71
  "summary-type-size": false,
71
72
  "transparent-padding-x": 0,
72
73
  "transparent-padding-y": 1em,
74
+ "borderless-margin-between" : 0.5rem
73
75
  ) !default;
74
76
 
75
77
  /// Change modules $config
@@ -212,8 +214,13 @@ $config: (
212
214
  }
213
215
  }
214
216
  }
215
- #{ $prefix }--no-borders {
217
+ #{ $prefix }--borderless {
216
218
  border: none;
219
+ & + & {
220
+ $gap: -(get("margin") - get("borderless-margin-between"));
221
+ margin-top: $gap;
222
+ margin-top: calc($gap - get("border-width"));
223
+ }
217
224
  &[open],
218
225
  &.is-active {
219
226
  & > .accordion__summary {
@@ -40,6 +40,8 @@ $-fallbacks: (
40
40
  /// @prop {Dimension} tabpanel-padding [(2rem,)] Padding for the tabpanel
41
41
  /// @prop {Dimension} indicator-size [0.25em] The size of the tab's active border/indicator
42
42
  /// @prop {Color} indicator-color [currentColor] The color of the indicator
43
+ /// @prop {Color} indicator-transition-duration [200ms] The transition duration for indicator
44
+ /// @prop {Color} indicator-scale-start [0] The starting scale for the indicator (set to 1 to disable expanding on click)
43
45
  /// @prop {Color} tab-color [link] The type color for the tabs. This uses color.scss, so the value of this options should be a variable from color.scss.
44
46
  /// @prop {Color} tab-color-hover [link-hover] The type color for the tabs when hovered or focused. This uses color.scss, so the value of this options should be a variable from color.scss.
45
47
  /// @prop {Color} tab-color-selected [selected] The tab type color when selected. This uses color.scss, so the value of this options should be a variable from color.scss.
@@ -62,8 +64,11 @@ $config: (
62
64
  "tablist-divider-width" : 1px,
63
65
  "indicator-size" : 3px,
64
66
  "indicator-color" : currentColor,
67
+ "indicator-transition-duration" : 200ms,
68
+ "indicator-transition-timing" : ease-out,
69
+ "indicator-scale-start" : 0,
65
70
  "tab-color" : "type-tertiary",
66
- "tab-color-hover" : "link-hover",
71
+ "tab-color-hover" : "selected",
67
72
  "tab-color-selected" : "selected",
68
73
  "tab-background-color-selected" : null,
69
74
  "tab-font-weight" : true,
@@ -142,17 +147,27 @@ $config: (
142
147
  left: 0;
143
148
  right: 0;
144
149
  height: get("indicator-size");
150
+ transition-property: opacity, background-color, transform;
151
+ transition-duration: get("indicator-transition-duration");
152
+ transition-timing-function: get("indicator-transition-timing");
153
+ transform: scaleX(get("indicator-scale-start"));
154
+ transform-origin: center;
145
155
  }
146
156
  &:hover {
147
157
  color: color.get(get("tab-color-hover"));
148
158
  }
159
+ // Add focus so as user clicks item it starts the active state styling
160
+ &:focus,
149
161
  &[aria-selected="true"] {
150
- color: color.get(get("tab-color-selected"));
151
- background-color: color.get(get("tab-background-color-selected"));
152
162
  &::after {
153
163
  opacity: 1;
164
+ transform: scaleX(1);
154
165
  }
155
166
  }
167
+ &[aria-selected="true"] {
168
+ color: color.get(get("tab-color-selected"));
169
+ background-color: color.get(get("tab-background-color-selected"));
170
+ }
156
171
  }
157
172
  [role="tabpanel"] {
158
173
  position: relative;