@coopdigital/styles 0.5.7 → 0.5.8
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/README.md
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
# Experience Kit for Styles
|
|
8
8
|
|
|
9
9
|
<!-- ALL-CONTRIBUTORS-BADGE:START - Do not remove or modify this section -->
|
|
10
|
-
[all_contributors_badge]: https://img.shields.io/badge/all_contributors-
|
|
10
|
+
[all_contributors_badge]: https://img.shields.io/badge/all_contributors-17-C08A00.svg ''
|
|
11
11
|
<!-- ALL-CONTRIBUTORS-BADGE:END -->
|
|
12
12
|
|
|
13
13
|
<a href="https://www.npmjs.com/package/@coopdigital/styles"><img src="https://img.shields.io/npm/v/%40coopdigital%2Fstyles?color=E85A00" alt="npm version" /></a>
|
|
@@ -113,19 +113,24 @@ Thanks goes to these wonderful people:
|
|
|
113
113
|
<div><img src="https://secure.gravatar.com/avatar/faf90b70d749cf9460eb603fa1700add94fd7d3a32645b4be6fa12eb45c4ffa3?s=80&d=identicon" width="200px;" alt=""/></div>
|
|
114
114
|
<small>Omid Kashan</small>
|
|
115
115
|
<div><a href="#a11y-omid.kashan" title="Accessibility">️️️️♿️</a> <a href="#code-omid.kashan" title="Code">💻</a> <a href="#doc-omid.kashan" title="Documentation">📖</a> <a href="#test-omid.kashan" title="Tests">⚠️</a></div>
|
|
116
|
+
</a></td>
|
|
117
|
+
<td align="center" valign="top" width="14.28%"><a href="https://gitlab.com/phil.wolstenholme">
|
|
118
|
+
<div><img src="https://gitlab.com/uploads/-/system/user/avatar/25900363/avatar.png" width="200px;" alt=""/></div>
|
|
119
|
+
<small>Phil Wolstenholme</small>
|
|
120
|
+
<div><a href="#a11y-phil.wolstenholme" title="Accessibility">️️️️♿️</a></div>
|
|
116
121
|
</a></td>
|
|
117
122
|
<td align="center" valign="top" width="14.28%"><a href="https://gitlab.com/romain.chen">
|
|
118
123
|
<div><img src="https://s3.eu-west-1.amazonaws.com/assets.digital.coop.co.uk/oneweb/blank.jpg" width="200px;" alt=""/></div>
|
|
119
124
|
<small>Romain Chen</small>
|
|
120
125
|
<div><a href="#design-romain.chen" title="Design">🎨</a></div>
|
|
121
126
|
</a></td>
|
|
127
|
+
</tr><br />
|
|
128
|
+
<tr>
|
|
122
129
|
<td align="center" valign="top" width="14.28%"><a href="https://gitlab.com/sam.harden">
|
|
123
130
|
<div><img src="https://ca.slack-edge.com/T0C9E3ZF0-U03NT7D39L6-2fc82e7f7c6e-150" width="200px;" alt=""/></div>
|
|
124
131
|
<small>Sam Harden</small>
|
|
125
132
|
<div><a href="#a11y-sam.harden" title="Accessibility">️️️️♿️</a> <a href="#code-sam.harden" title="Code">💻</a> <a href="#doc-sam.harden" title="Documentation">📖</a> <a href="#test-sam.harden" title="Tests">⚠️</a></div>
|
|
126
133
|
</a></td>
|
|
127
|
-
</tr><br />
|
|
128
|
-
<tr>
|
|
129
134
|
<td align="center" valign="top" width="14.28%"><a href="">
|
|
130
135
|
<div><img src="https://s3.eu-west-1.amazonaws.com/assets.digital.coop.co.uk/oneweb/blank.jpg" width="200px;" alt=""/></div>
|
|
131
136
|
<small>Shweta Jaju</small>
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
color: var(--text-color);
|
|
16
16
|
background-color: var(--bg-color);
|
|
17
17
|
}
|
|
18
|
-
.coop-alert-banner--inner
|
|
18
|
+
.coop-alert-banner--inner h2,
|
|
19
19
|
.coop-alert-banner--inner p {
|
|
20
20
|
margin: 0 0 var(--spacing-8) 0;
|
|
21
21
|
}
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
color: inherit;
|
|
27
27
|
text-decoration: none;
|
|
28
28
|
}
|
|
29
|
-
.coop-alert-banner--inner
|
|
29
|
+
.coop-alert-banner--inner h2 {
|
|
30
30
|
font-size: var(--type-size-22);
|
|
31
31
|
font-weight: 500;
|
|
32
32
|
}
|
|
@@ -1,51 +1,69 @@
|
|
|
1
1
|
.coop-editorial-card {
|
|
2
2
|
--flex-direction: column;
|
|
3
3
|
--image-max-width: 100%;
|
|
4
|
+
--image-border-radius: var(--ui-border-radius-m) var(--ui-border-radius-m) 0 0;
|
|
5
|
+
display: flex;
|
|
6
|
+
position: relative;
|
|
7
|
+
flex-direction: var(--flex-direction);
|
|
4
8
|
border-radius: var(--ui-border-radius-m);
|
|
5
9
|
box-shadow: var(--ui-shadow);
|
|
6
10
|
transition: box-shadow var(--ui-transition-hover);
|
|
7
11
|
}
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
12
|
+
@media (min-width: 48em) {
|
|
13
|
+
.coop-editorial-card[data-layout=horizontal] {
|
|
14
|
+
--flex-direction: row;
|
|
15
|
+
--image-max-width: calc(100% / 3);
|
|
16
|
+
--image-border-radius: var(--ui-border-radius-m) 0 0 var(--ui-border-radius-m);
|
|
17
|
+
}
|
|
11
18
|
}
|
|
12
19
|
.coop-editorial-card:hover, .coop-editorial-card:focus {
|
|
13
20
|
box-shadow: var(--ui-shadow-hover);
|
|
14
21
|
}
|
|
15
|
-
.coop-editorial-card
|
|
16
|
-
|
|
17
|
-
|
|
22
|
+
.coop-editorial-card h2,
|
|
23
|
+
.coop-editorial-card h3,
|
|
24
|
+
.coop-editorial-card h4,
|
|
25
|
+
.coop-editorial-card h5,
|
|
26
|
+
.coop-editorial-card h6 {
|
|
18
27
|
margin: 0;
|
|
28
|
+
font-size: var(--type-size-20);
|
|
29
|
+
font-weight: var(--type-weight-demibold);
|
|
19
30
|
}
|
|
20
31
|
.coop-editorial-card picture {
|
|
21
|
-
margin: 0;
|
|
22
|
-
max-width: var(--image-max-width);
|
|
23
32
|
overflow: hidden;
|
|
33
|
+
max-width: var(--image-max-width);
|
|
34
|
+
margin: 0;
|
|
35
|
+
border-radius: var(--image-border-radius);
|
|
24
36
|
}
|
|
25
37
|
.coop-editorial-card img {
|
|
38
|
+
width: 100%;
|
|
26
39
|
height: 100%;
|
|
27
40
|
}
|
|
28
41
|
.coop-editorial-card p {
|
|
29
42
|
margin: 0;
|
|
30
43
|
}
|
|
31
44
|
.coop-editorial-card a {
|
|
32
|
-
display: block;
|
|
33
|
-
text-decoration: none;
|
|
34
45
|
color: inherit;
|
|
46
|
+
text-decoration: none;
|
|
47
|
+
outline: 0;
|
|
48
|
+
}
|
|
49
|
+
.coop-editorial-card a::before {
|
|
50
|
+
content: "";
|
|
51
|
+
position: absolute;
|
|
52
|
+
inset: 0 0 0 0;
|
|
53
|
+
border-radius: var(--ui-border-radius-m);
|
|
54
|
+
}
|
|
55
|
+
.coop-editorial-card a:focus-within::before {
|
|
56
|
+
outline: 2px solid var(--color-focus-ring);
|
|
57
|
+
outline-offset: 3px;
|
|
35
58
|
}
|
|
36
59
|
.coop-editorial-card a:hover h3, .coop-editorial-card a:focus h3 {
|
|
37
60
|
text-decoration: underline;
|
|
38
61
|
}
|
|
39
|
-
.coop-editorial-card--inner {
|
|
40
|
-
display: flex;
|
|
41
|
-
flex-direction: var(--flex-direction);
|
|
42
|
-
overflow: hidden;
|
|
43
|
-
border-radius: var(--ui-border-radius-m);
|
|
44
|
-
}
|
|
45
62
|
.coop-editorial-card--content {
|
|
46
63
|
display: flex;
|
|
47
64
|
flex-direction: column;
|
|
48
65
|
gap: var(--spacing-12);
|
|
49
66
|
padding: var(--spacing-20);
|
|
67
|
+
border-radius: var(--ui-border-radius-m);
|
|
50
68
|
background: var(--color-white);
|
|
51
69
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@coopdigital/styles",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.5.
|
|
4
|
+
"version": "0.5.8",
|
|
5
5
|
"private": false,
|
|
6
6
|
"publishConfig": {
|
|
7
7
|
"access": "public"
|
|
@@ -31,5 +31,5 @@
|
|
|
31
31
|
"glob": "^11.0.1",
|
|
32
32
|
"sass-embedded": "^1.86.0"
|
|
33
33
|
},
|
|
34
|
-
"gitHead": "
|
|
34
|
+
"gitHead": "60cbbc73c648be7d728d36a700bcf2761579548f"
|
|
35
35
|
}
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
color: var(--text-color);
|
|
19
19
|
background-color: var(--bg-color);
|
|
20
20
|
|
|
21
|
-
|
|
21
|
+
h2,
|
|
22
22
|
p {
|
|
23
23
|
margin: 0 0 var(--spacing-8) 0;
|
|
24
24
|
}
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
}
|
|
33
33
|
}
|
|
34
34
|
|
|
35
|
-
|
|
35
|
+
h2 {
|
|
36
36
|
font-size: var(--type-size-22);
|
|
37
37
|
font-weight: 500;
|
|
38
38
|
}
|
|
@@ -1,13 +1,23 @@
|
|
|
1
|
+
@use "../breakpoints.scss" as *;
|
|
2
|
+
|
|
1
3
|
.coop-editorial-card {
|
|
2
4
|
--flex-direction: column;
|
|
3
5
|
--image-max-width: 100%;
|
|
6
|
+
--image-border-radius: var(--ui-border-radius-m) var(--ui-border-radius-m) 0 0;
|
|
7
|
+
|
|
8
|
+
display: flex;
|
|
9
|
+
position: relative;
|
|
10
|
+
flex-direction: var(--flex-direction);
|
|
4
11
|
border-radius: var(--ui-border-radius-m);
|
|
5
12
|
box-shadow: var(--ui-shadow);
|
|
6
13
|
transition: box-shadow var(--ui-transition-hover);
|
|
7
14
|
|
|
8
15
|
&[data-layout="horizontal"] {
|
|
9
|
-
|
|
10
|
-
|
|
16
|
+
@media (min-width: $mq-medium) {
|
|
17
|
+
--flex-direction: row;
|
|
18
|
+
--image-max-width: calc(100% / 3);
|
|
19
|
+
--image-border-radius: var(--ui-border-radius-m) 0 0 var(--ui-border-radius-m);
|
|
20
|
+
}
|
|
11
21
|
}
|
|
12
22
|
|
|
13
23
|
&:hover,
|
|
@@ -15,19 +25,25 @@
|
|
|
15
25
|
box-shadow: var(--ui-shadow-hover);
|
|
16
26
|
}
|
|
17
27
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
28
|
+
h2,
|
|
29
|
+
h3,
|
|
30
|
+
h4,
|
|
31
|
+
h5,
|
|
32
|
+
h6 {
|
|
21
33
|
margin: 0;
|
|
34
|
+
font-size: var(--type-size-20);
|
|
35
|
+
font-weight: var(--type-weight-demibold);
|
|
22
36
|
}
|
|
23
37
|
|
|
24
38
|
picture {
|
|
25
|
-
margin: 0;
|
|
26
|
-
max-width: var(--image-max-width);
|
|
27
39
|
overflow: hidden;
|
|
40
|
+
max-width: var(--image-max-width);
|
|
41
|
+
margin: 0;
|
|
42
|
+
border-radius: var(--image-border-radius);
|
|
28
43
|
}
|
|
29
44
|
|
|
30
45
|
img {
|
|
46
|
+
width: 100%;
|
|
31
47
|
height: 100%;
|
|
32
48
|
}
|
|
33
49
|
|
|
@@ -36,9 +52,23 @@
|
|
|
36
52
|
}
|
|
37
53
|
|
|
38
54
|
a {
|
|
39
|
-
display: block;
|
|
40
|
-
text-decoration: none;
|
|
41
55
|
color: inherit;
|
|
56
|
+
text-decoration: none;
|
|
57
|
+
outline: 0;
|
|
58
|
+
|
|
59
|
+
&::before {
|
|
60
|
+
content: "";
|
|
61
|
+
|
|
62
|
+
position: absolute;
|
|
63
|
+
inset: 0 0 0 0;
|
|
64
|
+
|
|
65
|
+
border-radius: var(--ui-border-radius-m);
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
&:focus-within::before {
|
|
69
|
+
outline: 2px solid var(--color-focus-ring);
|
|
70
|
+
outline-offset: 3px;
|
|
71
|
+
}
|
|
42
72
|
|
|
43
73
|
&:hover,
|
|
44
74
|
&:focus {
|
|
@@ -48,18 +78,14 @@
|
|
|
48
78
|
}
|
|
49
79
|
}
|
|
50
80
|
|
|
51
|
-
&--inner {
|
|
52
|
-
display: flex;
|
|
53
|
-
flex-direction: var(--flex-direction);
|
|
54
|
-
overflow: hidden;
|
|
55
|
-
border-radius: var(--ui-border-radius-m);
|
|
56
|
-
}
|
|
57
|
-
|
|
58
81
|
&--content {
|
|
59
82
|
display: flex;
|
|
60
83
|
flex-direction: column;
|
|
61
84
|
gap: var(--spacing-12);
|
|
85
|
+
|
|
62
86
|
padding: var(--spacing-20);
|
|
87
|
+
border-radius: var(--ui-border-radius-m);
|
|
88
|
+
|
|
63
89
|
background: var(--color-white);
|
|
64
90
|
}
|
|
65
91
|
}
|