@1024pix/pix-ui 55.1.0 → 55.3.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.
|
@@ -1,11 +1,19 @@
|
|
|
1
|
+
import { warn } from '@ember/debug';
|
|
1
2
|
import Component from '@glimmer/component';
|
|
2
3
|
|
|
3
4
|
export default class PixBlockComponent extends Component {
|
|
4
5
|
text = 'pix-block';
|
|
5
6
|
|
|
6
|
-
get
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
get variant() {
|
|
8
|
+
const value = this.args.variant ?? 'default';
|
|
9
|
+
warn(
|
|
10
|
+
`PixBlock: @variant "${value}" should be default, certif, orga or admin`,
|
|
11
|
+
['default', 'orga', 'certif', 'admin'].includes(value),
|
|
12
|
+
{
|
|
13
|
+
id: 'pix-ui.pix-block.variant.not-valid',
|
|
14
|
+
},
|
|
15
|
+
);
|
|
16
|
+
|
|
17
|
+
return value;
|
|
10
18
|
}
|
|
11
19
|
}
|
|
@@ -3,13 +3,25 @@
|
|
|
3
3
|
.pix-block {
|
|
4
4
|
position: relative;
|
|
5
5
|
background-color: var(--pix-neutral-0);
|
|
6
|
-
border-radius:
|
|
6
|
+
border-radius: var(--pix-spacing-2x);
|
|
7
7
|
|
|
8
|
-
&--
|
|
9
|
-
|
|
8
|
+
&--default {
|
|
9
|
+
padding: var(--pix-spacing-6x);
|
|
10
|
+
border: solid 1px var(--pix-primary-100);
|
|
10
11
|
}
|
|
11
12
|
|
|
12
|
-
&--
|
|
13
|
-
|
|
13
|
+
&--orga {
|
|
14
|
+
padding: var(--pix-spacing-3x);
|
|
15
|
+
border: solid 1px rgb(var(--pix-orga-500-inline), 0.45);
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
&--certif {
|
|
19
|
+
padding: var(--pix-spacing-3x);
|
|
20
|
+
border: solid 1px rgb(var(--pix-certif-500-inline), 0.45);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
&--admin {
|
|
24
|
+
padding: var(--pix-spacing-3x);
|
|
25
|
+
border: solid 1px var(--pix-primary-100);
|
|
14
26
|
}
|
|
15
27
|
}
|
|
@@ -80,6 +80,17 @@
|
|
|
80
80
|
letter-spacing: calc(-0.01 * var(--font-size-title));
|
|
81
81
|
}
|
|
82
82
|
|
|
83
|
+
%pix-title-xxs,
|
|
84
|
+
.pix-title-xxs {
|
|
85
|
+
@extend %-pix-title;
|
|
86
|
+
|
|
87
|
+
--font-size-title: 1.125rem;
|
|
88
|
+
|
|
89
|
+
font-size: var(--font-size-title);
|
|
90
|
+
line-height: 1.625;
|
|
91
|
+
letter-spacing: calc(-0.01 * var(--font-size-title));
|
|
92
|
+
}
|
|
93
|
+
|
|
83
94
|
%-pix-body {
|
|
84
95
|
font-weight: var(--pix-font-normal);
|
|
85
96
|
|