@gitlab/ui 63.1.1 → 63.1.2

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": "@gitlab/ui",
3
- "version": "63.1.1",
3
+ "version": "63.1.2",
4
4
  "description": "GitLab UI Components",
5
5
  "license": "MIT",
6
6
  "main": "dist/index.js",
@@ -9,56 +9,65 @@
9
9
  @include gl-py-5;
10
10
 
11
11
  &.indigo {
12
- @include gl-bg-theme-indigo-700;
12
+ --gl-broadcast-message-bg-color: #{$theme-indigo-700};
13
+ --gl-broadcast-message-border-color: #{$theme-indigo-900};
13
14
  }
14
15
 
15
16
  &.light-indigo {
16
- @include gl-bg-theme-indigo-500;
17
+ --gl-broadcast-message-bg-color: #{$theme-indigo-500};
18
+ --gl-broadcast-message-border-color: #{$theme-indigo-700};
17
19
  }
18
20
 
19
21
  &.blue {
20
- @include gl-bg-theme-blue-700;
22
+ --gl-broadcast-message-bg-color: #{$theme-blue-700};
23
+ --gl-broadcast-message-border-color: #{$theme-blue-900};
21
24
  }
22
25
 
23
26
  &.light-blue {
24
- @include gl-bg-theme-blue-500;
27
+ --gl-broadcast-message-bg-color: #{$theme-blue-500};
28
+ --gl-broadcast-message-border-color: #{$theme-blue-700};
25
29
  }
26
30
 
27
31
  &.green {
28
- @include gl-bg-theme-green-700;
32
+ --gl-broadcast-message-bg-color: #{$theme-green-700};
33
+ --gl-broadcast-message-border-color: #{$theme-green-900};
29
34
  }
30
35
 
31
36
  &.light-green {
32
- @include gl-bg-theme-green-500;
37
+ --gl-broadcast-message-bg-color: #{$theme-green-500};
38
+ --gl-broadcast-message-border-color: #{$theme-green-700};
33
39
  }
34
40
 
35
41
  &.red {
36
- @include gl-bg-theme-red-700;
42
+ --gl-broadcast-message-bg-color: #{$theme-red-700};
43
+ --gl-broadcast-message-border-color: #{$theme-red-900};
37
44
  }
38
45
 
39
46
  &.light-red {
40
- @include gl-bg-theme-red-500;
47
+ --gl-broadcast-message-bg-color: #{$theme-red-500};
48
+ --gl-broadcast-message-border-color: #{$theme-red-700};
41
49
  }
42
50
 
43
51
  &.dark {
44
- @include gl-bg-gray-500;
52
+ --gl-broadcast-message-bg-color: #{$gray-500};
53
+ --gl-broadcast-message-border-color: #{$gray-700};
45
54
  }
46
55
 
47
56
  &.light {
48
- @include gl-bg-gray-300;
57
+ --gl-broadcast-message-bg-color: #{$gray-300};
58
+ --gl-broadcast-message-border-color: #{$gray-500};
49
59
  }
50
60
 
51
61
  &.banner {
52
62
  @include gl-text-contrast-light;
53
- @include gl-inset-border-b-1-gray-900;
63
+ background-color: var(--gl-broadcast-message-bg-color);
64
+ box-shadow: inset 0 -#{$gl-border-size-1} 0 0 var(--gl-broadcast-message-border-color);
54
65
  }
55
66
 
56
67
  &.notification {
57
68
  @include gl-rounded-base;
58
69
  @include gl-bg-white;
59
- @include gl-border-solid;
60
- @include gl-border-gray-100;
61
- @include gl-border-1;
70
+ @include gl-border;
62
71
  @include gl-shadow-x0-y2-b4-s0;
63
72
  max-width: $gl-broadcast-message-notification-max-width;
64
73
  }
@@ -15,6 +15,17 @@ const template = `
15
15
  </gl-broadcast-message>
16
16
  `;
17
17
 
18
+ const templateWithTheme = (theme) => `
19
+ <gl-broadcast-message
20
+ :icon-name="iconName"
21
+ :dismissible="dismissible"
22
+ :dismiss-label="dismissLabel"
23
+ theme="${theme}"
24
+ :type="type">
25
+ {{ text }}
26
+ </gl-broadcast-message>
27
+ `;
28
+
18
29
  const defaultValue = (prop) => GlBroadcastMessage.props[prop].default;
19
30
 
20
31
  const generateProps = ({
@@ -58,7 +69,7 @@ const StackedStory = (args, { argTypes }) => ({
58
69
  GlBroadcastMessage,
59
70
  },
60
71
  props: Object.keys(argTypes),
61
- template: `<div>${template}${template}</div>`,
72
+ template: `<div>${Object.keys(colorThemes).map(templateWithTheme).join('')}</div>`,
62
73
  });
63
74
  export const Stacked = StackedStory.bind({});
64
75
  Stacked.args = generateProps();