@oslokommune/punkt-css 0.18.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/CHANGELOG.md +260 -0
- package/CONTRIBUTING.md +116 -0
- package/LICENSE +23 -0
- package/README.md +221 -0
- package/dist/css/components/alert.css +111 -0
- package/dist/css/components/alert.min.css +1 -0
- package/dist/css/components/backlink.css +38 -0
- package/dist/css/components/backlink.min.css +1 -0
- package/dist/css/components/badge.css +52 -0
- package/dist/css/components/badge.min.css +1 -0
- package/dist/css/components/breadcrumbs.css +116 -0
- package/dist/css/components/breadcrumbs.min.css +1 -0
- package/dist/css/components/footer.css +48 -0
- package/dist/css/components/footer.min.css +1 -0
- package/dist/css/components/header.css +123 -0
- package/dist/css/components/header.min.css +1 -0
- package/dist/css/components/icon.css +63 -0
- package/dist/css/components/icon.min.css +1 -0
- package/dist/css/components/teaserlist.css +53 -0
- package/dist/css/components/teaserlist.min.css +1 -0
- package/dist/css/pkt-base.css +9721 -0
- package/dist/css/pkt-base.min.css +1 -0
- package/dist/css/pkt-components.css +611 -0
- package/dist/css/pkt-components.min.css +1 -0
- package/dist/css/pkt-elements.css +881 -0
- package/dist/css/pkt-elements.min.css +1 -0
- package/dist/css/pkt-normalise.css +221 -0
- package/dist/css/pkt-normalise.min.css +1 -0
- package/dist/css/pkt.css +11415 -0
- package/dist/css/pkt.min.css +1 -0
- package/dist/scss/abstracts/_index.scss +3 -0
- package/dist/scss/abstracts/functions/_index.scss +65 -0
- package/dist/scss/abstracts/mixins/_breakpoints.scss +60 -0
- package/dist/scss/abstracts/mixins/_index.scss +2 -0
- package/dist/scss/abstracts/mixins/_typography.scss +45 -0
- package/dist/scss/abstracts/placeholders/_index.scss +19 -0
- package/dist/scss/abstracts/variables/_breakpoints.scss +8 -0
- package/dist/scss/abstracts/variables/_colors.scss +55 -0
- package/dist/scss/abstracts/variables/_index.scss +24 -0
- package/dist/scss/abstracts/variables/_spacing.scss +22 -0
- package/dist/scss/abstracts/variables/_typography.scss +430 -0
- package/dist/scss/base/_accessibility.scss +11 -0
- package/dist/scss/base/_colors.scss +24 -0
- package/dist/scss/base/_containers.scss +75 -0
- package/dist/scss/base/_defaults.scss +48 -0
- package/dist/scss/base/_grid.scss +114 -0
- package/dist/scss/base/_index.scss +9 -0
- package/dist/scss/base/_oslo-sans.scss +21 -0
- package/dist/scss/base/_spacing.scss +109 -0
- package/dist/scss/base/_typography.scss +102 -0
- package/dist/scss/base/_visibility.scss +28 -0
- package/dist/scss/components/_alert.scss +153 -0
- package/dist/scss/components/_backlink.scss +50 -0
- package/dist/scss/components/_badge.scss +59 -0
- package/dist/scss/components/_breadcrumbs.scss +130 -0
- package/dist/scss/components/_footer.scss +52 -0
- package/dist/scss/components/_header.scss +125 -0
- package/dist/scss/components/_icon.scss +83 -0
- package/dist/scss/components/_index.scss +8 -0
- package/dist/scss/components/_teaserlist.scss +56 -0
- package/dist/scss/elements/_button.scss +412 -0
- package/dist/scss/elements/_form.scss +190 -0
- package/dist/scss/elements/_hr.scss +8 -0
- package/dist/scss/elements/_image.scss +32 -0
- package/dist/scss/elements/_index.scss +8 -0
- package/dist/scss/elements/_list.scss +104 -0
- package/dist/scss/elements/_section.scss +98 -0
- package/dist/scss/elements/_select.scss +82 -0
- package/dist/scss/elements/_table.scss +80 -0
- package/dist/scss/normalise/_index.scss +241 -0
- package/dist/scss/pkt-base.scss +4 -0
- package/dist/scss/pkt-components.scss +4 -0
- package/dist/scss/pkt-elements.scss +4 -0
- package/dist/scss/pkt-normalise.scss +4 -0
- package/dist/scss/pkt.scss +13 -0
- package/index.js +1 -0
- package/package.json +40 -0
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Containers
|
|
3
|
+
*
|
|
4
|
+
* Containers er en viktig brikke for å bruke Oslo Designsystem, og som holder på,
|
|
5
|
+
* gir luft rundt og justerer innholdet innenfor en skjermstørrelse.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
@use 'sass:map';
|
|
9
|
+
@use 'sass:math';
|
|
10
|
+
@use '../abstracts/variables';
|
|
11
|
+
@use '../abstracts/mixins/breakpoints' as *;
|
|
12
|
+
|
|
13
|
+
$-gapsSmall: map.get(variables.$spacing, 'size-16');
|
|
14
|
+
$-gapsMedium: map.get(variables.$spacing, 'size-32');
|
|
15
|
+
|
|
16
|
+
.pkt-container {
|
|
17
|
+
margin-left: auto;
|
|
18
|
+
margin-right: auto;
|
|
19
|
+
padding-left: $-gapsSmall;
|
|
20
|
+
padding-right: $-gapsSmall;
|
|
21
|
+
width: 100%;
|
|
22
|
+
|
|
23
|
+
@include bp('tablet-up') {
|
|
24
|
+
padding-left: $-gapsMedium;
|
|
25
|
+
padding-right: $-gapsMedium;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
@include bp('laptop-up') {
|
|
29
|
+
max-width: map.get(variables.$breakpoints, 'laptop');
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
// Widths
|
|
33
|
+
&--full {
|
|
34
|
+
max-width: 100%;
|
|
35
|
+
}
|
|
36
|
+
@include bp('phablet-up') {
|
|
37
|
+
&--phablet {
|
|
38
|
+
max-width: map.get(variables.$breakpoints, 'phablet');
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
@include bp('tablet-up') {
|
|
42
|
+
&--tablet {
|
|
43
|
+
max-width: map.get(variables.$breakpoints, 'tablet');
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
@include bp('tablet-big-up') {
|
|
47
|
+
&--tablet-big {
|
|
48
|
+
max-width: map.get(variables.$breakpoints, 'tablet-big');
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
@include bp('laptop-up') {
|
|
52
|
+
&--laptop {
|
|
53
|
+
max-width: map.get(variables.$breakpoints, 'laptop');
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
@include bp('desktop-up') {
|
|
57
|
+
&--desktop {
|
|
58
|
+
max-width: map.get(variables.$breakpoints, 'desktop');
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
// Alignment
|
|
63
|
+
&--left {
|
|
64
|
+
margin-left: 0;
|
|
65
|
+
margin-right: auto;
|
|
66
|
+
}
|
|
67
|
+
&--center {
|
|
68
|
+
margin-left: auto;
|
|
69
|
+
margin-right: auto;
|
|
70
|
+
}
|
|
71
|
+
&--right {
|
|
72
|
+
margin-left: auto;
|
|
73
|
+
margin-right: 0;
|
|
74
|
+
}
|
|
75
|
+
}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Defaults for elementer
|
|
3
|
+
*
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
body,
|
|
7
|
+
h1,
|
|
8
|
+
h2,
|
|
9
|
+
h3,
|
|
10
|
+
h4,
|
|
11
|
+
p,
|
|
12
|
+
ul,
|
|
13
|
+
ol,
|
|
14
|
+
li,
|
|
15
|
+
figure,
|
|
16
|
+
figcaption,
|
|
17
|
+
blockquote,
|
|
18
|
+
dl,
|
|
19
|
+
dd {
|
|
20
|
+
margin: 0;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
h1,
|
|
24
|
+
h2,
|
|
25
|
+
h3,
|
|
26
|
+
h4,
|
|
27
|
+
h5,
|
|
28
|
+
h6 {
|
|
29
|
+
font-weight: normal;
|
|
30
|
+
font-size: 1rem;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
img,
|
|
34
|
+
svg {
|
|
35
|
+
vertical-align: middle;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
p {
|
|
39
|
+
display: block;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
body {
|
|
43
|
+
min-height: 100vh;
|
|
44
|
+
overflow-y: scroll;
|
|
45
|
+
line-height: 1.5;
|
|
46
|
+
text-rendering: optimizeSpeed;
|
|
47
|
+
scroll-behavior: smooth;
|
|
48
|
+
}
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* CSS Grid layouts
|
|
3
|
+
*/
|
|
4
|
+
@use 'sass:map';
|
|
5
|
+
@use 'sass:math';
|
|
6
|
+
@use '../abstracts/variables';
|
|
7
|
+
@use '../abstracts/mixins/breakpoints' as *;
|
|
8
|
+
|
|
9
|
+
$gapsSmall: map.get(variables.$spacing, 'size-16');
|
|
10
|
+
$gapsMedium: map.get(variables.$spacing, 'size-32');
|
|
11
|
+
|
|
12
|
+
.pkt-grid {
|
|
13
|
+
display: grid;
|
|
14
|
+
gap: $gapsSmall;
|
|
15
|
+
grid-template-columns: repeat(12, 1fr);
|
|
16
|
+
margin-left: auto;
|
|
17
|
+
margin-right: auto;
|
|
18
|
+
width: 100%;
|
|
19
|
+
|
|
20
|
+
@include bp('tablet-up') {
|
|
21
|
+
gap: $gapsMedium;
|
|
22
|
+
}
|
|
23
|
+
// Widths
|
|
24
|
+
&--full {
|
|
25
|
+
max-width: 100%;
|
|
26
|
+
}
|
|
27
|
+
@include bp('phablet-up') {
|
|
28
|
+
&--phablet {
|
|
29
|
+
max-width: map.get(variables.$breakpoints, 'phablet');
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
@include bp('tablet-up') {
|
|
33
|
+
&--tablet {
|
|
34
|
+
max-width: map.get(variables.$breakpoints, 'tablet');
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
@include bp('tablet-big-up') {
|
|
38
|
+
&--tablet-big {
|
|
39
|
+
max-width: map.get(variables.$breakpoints, 'tablet-big');
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
@include bp('laptop-up') {
|
|
43
|
+
&--laptop {
|
|
44
|
+
max-width: map.get(variables.$breakpoints, 'laptop');
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
@include bp('desktop-up') {
|
|
48
|
+
&--desktop {
|
|
49
|
+
max-width: map.get(variables.$breakpoints, 'desktop');
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
// Alignment
|
|
54
|
+
&--left {
|
|
55
|
+
margin-left: 0;
|
|
56
|
+
margin-right: auto;
|
|
57
|
+
}
|
|
58
|
+
&--center {
|
|
59
|
+
margin-left: auto;
|
|
60
|
+
margin-right: auto;
|
|
61
|
+
}
|
|
62
|
+
&--right {
|
|
63
|
+
margin-left: auto;
|
|
64
|
+
margin-right: 0;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
// Gap
|
|
68
|
+
@each $sp-name, $sp-value in variables.$spacing {
|
|
69
|
+
&--gap-#{$sp-name} {
|
|
70
|
+
gap: $sp-value;
|
|
71
|
+
}
|
|
72
|
+
&--colgap-#{$sp-name} {
|
|
73
|
+
column-gap: $sp-value;
|
|
74
|
+
}
|
|
75
|
+
&--rowgap-#{$sp-name} {
|
|
76
|
+
row-gap: $sp-value;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
@each $bp-name, $bp-value in variables.$breakpoints {
|
|
81
|
+
@include bp('#{$bp-value}') {
|
|
82
|
+
@each $sp-name, $sp-value in variables.$spacing {
|
|
83
|
+
&--gap-#{$sp-name}-#{$bp-name}-up {
|
|
84
|
+
gap: $sp-value;
|
|
85
|
+
}
|
|
86
|
+
&--colgap-#{$sp-name}-#{$bp-name}-up {
|
|
87
|
+
column-gap: $sp-value;
|
|
88
|
+
}
|
|
89
|
+
&--rowgap-#{$sp-name}-#{$bp-name}-up {
|
|
90
|
+
row-gap: $sp-value;
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
// grid cell
|
|
97
|
+
& > .pkt-cell {
|
|
98
|
+
@for $i from 2 through 12 {
|
|
99
|
+
&.pkt-cell--span#{$i} {
|
|
100
|
+
grid-column-end: span $i;
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
@each $bp-name, $bp-value in variables.$breakpoints {
|
|
105
|
+
@include bp('#{$bp-value}') {
|
|
106
|
+
@for $i from 2 through 12 {
|
|
107
|
+
&.pkt-cell--span#{$i}-#{$bp-name}-up {
|
|
108
|
+
grid-column-end: span $i;
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Oslo-sans
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
@use "sass:map";
|
|
6
|
+
@use "../abstracts/variables";
|
|
7
|
+
|
|
8
|
+
@mixin font-face($font) {
|
|
9
|
+
@font-face {
|
|
10
|
+
font-display: swap;
|
|
11
|
+
font-family: map.get($font, 'family');
|
|
12
|
+
font-style: map.get($font, 'style');
|
|
13
|
+
font-weight: map.get($font, 'weight');
|
|
14
|
+
src: url(map.get($font, 'src-woff2')) format('woff2'),
|
|
15
|
+
url(map.get($font, 'src-woff')) format('woff');
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
@each $name, $attr in variables.$font-face {
|
|
20
|
+
@include font-face($attr);
|
|
21
|
+
}
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Spacing
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
@use "sass:map";
|
|
6
|
+
@use "../abstracts/variables";
|
|
7
|
+
@use "../abstracts/mixins/breakpoints" as *;
|
|
8
|
+
|
|
9
|
+
@each $sp-name, $sp-value in variables.$spacing {
|
|
10
|
+
.m-#{$sp-name} {
|
|
11
|
+
margin: $sp-value !important;
|
|
12
|
+
}
|
|
13
|
+
.mt-#{$sp-name} {
|
|
14
|
+
margin-top: $sp-value !important;
|
|
15
|
+
}
|
|
16
|
+
.mr-#{$sp-name} {
|
|
17
|
+
margin-right: $sp-value !important;
|
|
18
|
+
}
|
|
19
|
+
.mb-#{$sp-name} {
|
|
20
|
+
margin-bottom: $sp-value !important;
|
|
21
|
+
}
|
|
22
|
+
.ml-#{$sp-name} {
|
|
23
|
+
margin-left: $sp-value !important;
|
|
24
|
+
}
|
|
25
|
+
.mx-#{$sp-name} {
|
|
26
|
+
margin-right: $sp-value !important;
|
|
27
|
+
margin-left: $sp-value !important;
|
|
28
|
+
}
|
|
29
|
+
.my-#{$sp-name} {
|
|
30
|
+
margin-top: $sp-value !important;
|
|
31
|
+
margin-bottom: $sp-value !important;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.p-#{$sp-name} {
|
|
35
|
+
padding: $sp-value !important;
|
|
36
|
+
}
|
|
37
|
+
.pt-#{$sp-name} {
|
|
38
|
+
padding-top: $sp-value !important;
|
|
39
|
+
}
|
|
40
|
+
.pr-#{$sp-name} {
|
|
41
|
+
padding-right: $sp-value !important;
|
|
42
|
+
}
|
|
43
|
+
.pb-#{$sp-name} {
|
|
44
|
+
padding-bottom: $sp-value !important;
|
|
45
|
+
}
|
|
46
|
+
.pl-#{$sp-name} {
|
|
47
|
+
padding-left: $sp-value !important;
|
|
48
|
+
}
|
|
49
|
+
.px-#{$sp-name} {
|
|
50
|
+
padding-right: $sp-value !important;
|
|
51
|
+
padding-left: $sp-value !important;
|
|
52
|
+
}
|
|
53
|
+
.py-#{$sp-name} {
|
|
54
|
+
padding-top: $sp-value !important;
|
|
55
|
+
padding-bottom: $sp-value !important;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
@each $bp-name, $bp-value in variables.$breakpoints {
|
|
59
|
+
@include bp('#{$bp-value}') {
|
|
60
|
+
.m-#{$sp-name}--#{$bp-name}-up {
|
|
61
|
+
margin: $sp-value !important;
|
|
62
|
+
}
|
|
63
|
+
.mt-#{$sp-name}--#{$bp-name}-up {
|
|
64
|
+
margin-top: $sp-value !important;
|
|
65
|
+
}
|
|
66
|
+
.mr-#{$sp-name}--#{$bp-name}-up {
|
|
67
|
+
margin-right: $sp-value !important;
|
|
68
|
+
}
|
|
69
|
+
.mb-#{$sp-name}--#{$bp-name}-up {
|
|
70
|
+
margin-bottom: $sp-value !important;
|
|
71
|
+
}
|
|
72
|
+
.ml-#{$sp-name}--#{$bp-name}-up {
|
|
73
|
+
margin-left: $sp-value !important;
|
|
74
|
+
}
|
|
75
|
+
.mx-#{$sp-name}--#{$bp-name}-up {
|
|
76
|
+
margin-right: $sp-value !important;
|
|
77
|
+
margin-left: $sp-value !important;
|
|
78
|
+
}
|
|
79
|
+
.my-#{$sp-name}--#{$bp-name}-up {
|
|
80
|
+
margin-top: $sp-value !important;
|
|
81
|
+
margin-bottom: $sp-value !important;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.p-#{$sp-name}--#{$bp-name}-up {
|
|
85
|
+
padding: $sp-value !important;
|
|
86
|
+
}
|
|
87
|
+
.pt-#{$sp-name}--#{$bp-name}-up {
|
|
88
|
+
padding-top: $sp-value !important;
|
|
89
|
+
}
|
|
90
|
+
.pr-#{$sp-name}--#{$bp-name}-up {
|
|
91
|
+
padding-right: $sp-value !important;
|
|
92
|
+
}
|
|
93
|
+
.pb-#{$sp-name}--#{$bp-name}-up {
|
|
94
|
+
padding-bottom: $sp-value !important;
|
|
95
|
+
}
|
|
96
|
+
.pl-#{$sp-name}--#{$bp-name}-up {
|
|
97
|
+
padding-left: $sp-value !important;
|
|
98
|
+
}
|
|
99
|
+
.px-#{$sp-name}--#{$bp-name}-up {
|
|
100
|
+
padding-right: $sp-value !important;
|
|
101
|
+
padding-left: $sp-value !important;
|
|
102
|
+
}
|
|
103
|
+
.py-#{$sp-name}--#{$bp-name}-up {
|
|
104
|
+
padding-top: $sp-value !important;
|
|
105
|
+
padding-bottom: $sp-value !important;
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
}
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Typografi
|
|
3
|
+
*
|
|
4
|
+
* Setter Oslo kommune-stiler
|
|
5
|
+
*
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
@use 'sass:map';
|
|
9
|
+
@use '../abstracts/variables';
|
|
10
|
+
@use '../abstracts/mixins/typography';
|
|
11
|
+
|
|
12
|
+
body {
|
|
13
|
+
color: var(--color-blue-dark);
|
|
14
|
+
font-family: #{map.get(variables.$font-family, 'normal')};
|
|
15
|
+
font-size: map.get(variables.$font-size, 'size-16');
|
|
16
|
+
font-weight: map.get(variables.$font-weight, 'light');
|
|
17
|
+
letter-spacing: map.get(variables.$letter-spacing, 'normal');
|
|
18
|
+
line-height: map.get(variables.$line-height, 'body');
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
em {
|
|
22
|
+
font-style: italic;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
small {
|
|
26
|
+
font-size: map.get(variables.$font-size, 'size-14');
|
|
27
|
+
opacity: 0.8;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
strong {
|
|
31
|
+
font-weight: map.get(variables.$font-weight, 'medium');
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
a {
|
|
35
|
+
color: var(--color-blue-dark);
|
|
36
|
+
text-decoration: underline;
|
|
37
|
+
word-wrap: break-word;
|
|
38
|
+
|
|
39
|
+
&:visited {
|
|
40
|
+
color: var(--color-visited);
|
|
41
|
+
}
|
|
42
|
+
&:focus {
|
|
43
|
+
color: var(--color-active);
|
|
44
|
+
}
|
|
45
|
+
&:hover {
|
|
46
|
+
color: var(--color-hover);
|
|
47
|
+
text-decoration: underline;
|
|
48
|
+
}
|
|
49
|
+
&:active {
|
|
50
|
+
color: var(--color-active);
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
@at-root [data-mode='dark'] a {
|
|
54
|
+
color: var(--color-white);
|
|
55
|
+
|
|
56
|
+
&:visited {
|
|
57
|
+
color: var(--color-visited-light);
|
|
58
|
+
}
|
|
59
|
+
&:focus {
|
|
60
|
+
color: var(--color-active-light);
|
|
61
|
+
}
|
|
62
|
+
&:hover {
|
|
63
|
+
color: var(--color-hover-light);
|
|
64
|
+
}
|
|
65
|
+
&:active {
|
|
66
|
+
color: var(--color-active-light);
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
/*
|
|
72
|
+
* origo typography
|
|
73
|
+
* prefix pkt
|
|
74
|
+
*/
|
|
75
|
+
|
|
76
|
+
@each $name, $style in variables.$pkt-styles {
|
|
77
|
+
@include typography.generate-text-class($name, $style);
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
@each $name, $style in variables.$pkt-font-weight {
|
|
81
|
+
@include typography.generate-text-class($name, $style);
|
|
82
|
+
}
|
|
83
|
+
/*
|
|
84
|
+
* Alignment
|
|
85
|
+
*/
|
|
86
|
+
.text-start {
|
|
87
|
+
text-align: left !important;
|
|
88
|
+
}
|
|
89
|
+
.text-end {
|
|
90
|
+
text-align: right !important;
|
|
91
|
+
}
|
|
92
|
+
.text-center {
|
|
93
|
+
text-align: center !important;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
/*
|
|
97
|
+
* Truncate text
|
|
98
|
+
* requires inline-block or block
|
|
99
|
+
*/
|
|
100
|
+
.truncate-text {
|
|
101
|
+
@include typography.truncate-text();
|
|
102
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Visibility
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
@use '../abstracts/variables' as *;
|
|
6
|
+
@use '../abstracts/mixins/breakpoints' as *;
|
|
7
|
+
|
|
8
|
+
.pkt-hide {
|
|
9
|
+
display: none !important;
|
|
10
|
+
}
|
|
11
|
+
.pkt-show {
|
|
12
|
+
display: block !important;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
@each $name, $value in $breakpoints {
|
|
16
|
+
.pkt-hide-#{$name}-up {
|
|
17
|
+
@include bp($value) {
|
|
18
|
+
display: none !important;
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.pkt-show-#{$name}-up {
|
|
23
|
+
@include bp('#{$value}') {
|
|
24
|
+
display: block !important;
|
|
25
|
+
}
|
|
26
|
+
display: none !important;
|
|
27
|
+
}
|
|
28
|
+
}
|
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Alert component
|
|
3
|
+
*/
|
|
4
|
+
@use 'sass:map';
|
|
5
|
+
@use '../abstracts/variables';
|
|
6
|
+
@use '../abstracts/mixins/breakpoints' as *;
|
|
7
|
+
@use '../abstracts/' as *;
|
|
8
|
+
|
|
9
|
+
// Spacing
|
|
10
|
+
$-alert-spacing: map.get(variables.$spacing, 'size-24');
|
|
11
|
+
|
|
12
|
+
//// Colors
|
|
13
|
+
$-alert-red-error: map.get(variables.$colors, 'color-error');
|
|
14
|
+
$-alert-green-dark: map.get(variables.$colors, 'color-green-dark');
|
|
15
|
+
$-alert-blue-dark: map.get(variables.$colors, 'color-blue-dark');
|
|
16
|
+
|
|
17
|
+
// Error
|
|
18
|
+
$-alert-error-border: 3px solid $-alert-red-error;
|
|
19
|
+
$-alert-error-bg: map.get(variables.$colors, 'color-red-5');
|
|
20
|
+
$-alert-error-color: $-alert-red-error;
|
|
21
|
+
|
|
22
|
+
// Success
|
|
23
|
+
$-alert-success-border: 3px solid $-alert-green-dark;
|
|
24
|
+
$-alert-success-bg: map.get(variables.$colors, 'color-green-dark-5');
|
|
25
|
+
$-alert-success-color: $-alert-green-dark;
|
|
26
|
+
|
|
27
|
+
// Warning
|
|
28
|
+
$-alert-warning-border: 3px solid map.get(variables.$colors, 'color-yellow');
|
|
29
|
+
$-alert-warning-bg: map.get(variables.$colors, 'color-yellow-5');
|
|
30
|
+
$-alert-warning-color: map.get(variables.$colors, 'color-warning');
|
|
31
|
+
|
|
32
|
+
// Info
|
|
33
|
+
$-alert-info-border: 3px solid $-alert-blue-dark;
|
|
34
|
+
$-alert-info-bg: map.get(variables.$colors, 'color-blue-dark-5');
|
|
35
|
+
$-alert-info-color: $-alert-blue-dark;
|
|
36
|
+
|
|
37
|
+
// Close hover color
|
|
38
|
+
$-alert-close-hover-color: map.get(variables.$colors, 'color-hover');
|
|
39
|
+
|
|
40
|
+
.pkt-alert {
|
|
41
|
+
padding: $-alert-spacing;
|
|
42
|
+
display: block;
|
|
43
|
+
overflow: hidden;
|
|
44
|
+
position: relative;
|
|
45
|
+
|
|
46
|
+
&__text {
|
|
47
|
+
@include get-text('pkt-txt-18-light');
|
|
48
|
+
margin-bottom: 0;
|
|
49
|
+
padding: 0;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
&__title {
|
|
53
|
+
@include get-text('pkt-txt-18-medium');
|
|
54
|
+
display: flex;
|
|
55
|
+
align-items: center;
|
|
56
|
+
margin-bottom: $-alert-spacing;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
&__content {
|
|
60
|
+
display: flex;
|
|
61
|
+
align-items: flex-start;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
&__date {
|
|
65
|
+
@include get-text('pkt-txt-14-light');
|
|
66
|
+
margin-top: $-alert-spacing;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
&__close {
|
|
70
|
+
display: flex;
|
|
71
|
+
float: right;
|
|
72
|
+
margin-left: $-alert-spacing;
|
|
73
|
+
height: 24px;
|
|
74
|
+
width: 24px;
|
|
75
|
+
|
|
76
|
+
svg:hover {
|
|
77
|
+
cursor: pointer;
|
|
78
|
+
background-color: $-alert-close-hover-color;
|
|
79
|
+
--fg-color: var(--color-blue-dark-5);
|
|
80
|
+
}
|
|
81
|
+
svg:focus {
|
|
82
|
+
background-color: $-alert-close-hover-color;
|
|
83
|
+
--fg-color: var(--color-blue-dark-5);
|
|
84
|
+
}
|
|
85
|
+
svg:active {
|
|
86
|
+
background-color: $-alert-close-hover-color;
|
|
87
|
+
--fg-color: var(--color-blue-dark-5);
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
&__icon {
|
|
92
|
+
margin-right: map.get(variables.$spacing, 'size-16');
|
|
93
|
+
height: 1.875rem;
|
|
94
|
+
width: 1.875rem;
|
|
95
|
+
flex-shrink: 0;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
// skins
|
|
99
|
+
// default is "info"
|
|
100
|
+
|
|
101
|
+
&--success {
|
|
102
|
+
border-left: $-alert-success-border;
|
|
103
|
+
background-color: $-alert-success-bg;
|
|
104
|
+
color: $-alert-success-color;
|
|
105
|
+
|
|
106
|
+
&.pkt-alert .pkt-alert__icon {
|
|
107
|
+
--bg-color: var(--color-green-dark);
|
|
108
|
+
--fg-color: var(--color-green-dark-5);
|
|
109
|
+
}
|
|
110
|
+
&.pkt-alert .pkt-alert__close {
|
|
111
|
+
--fg-color: var(--color-green-dark);
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
&--error {
|
|
116
|
+
border-left: $-alert-error-border;
|
|
117
|
+
background-color: $-alert-error-bg;
|
|
118
|
+
color: $-alert-error-color;
|
|
119
|
+
&.pkt-alert .pkt-alert__icon {
|
|
120
|
+
--bg-color: var(--color-error);
|
|
121
|
+
--fg-color: var(--color-red-5);
|
|
122
|
+
}
|
|
123
|
+
&.pkt-alert .pkt-alert__close {
|
|
124
|
+
--fg-color: var(--color-error);
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
&--warning {
|
|
129
|
+
border-left: $-alert-warning-border;
|
|
130
|
+
background-color: $-alert-warning-bg;
|
|
131
|
+
color: $-alert-warning-color;
|
|
132
|
+
&.pkt-alert .pkt-alert__icon {
|
|
133
|
+
--bg-color: var(--color-yellow);
|
|
134
|
+
--fg-color: var(--color-blue-dark);
|
|
135
|
+
}
|
|
136
|
+
&.pkt-alert .pkt-alert__close {
|
|
137
|
+
--fg-color: var(--color-warning);
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
&--info {
|
|
142
|
+
border-left: $-alert-info-border;
|
|
143
|
+
background-color: $-alert-info-bg;
|
|
144
|
+
color: $-alert-info-color;
|
|
145
|
+
&.pkt-alert .pkt-alert__icon {
|
|
146
|
+
--bg-color: var(--color-blue);
|
|
147
|
+
--fg-color: var(--color-blue-dark);
|
|
148
|
+
}
|
|
149
|
+
&.pkt-alert .pkt-alert__close {
|
|
150
|
+
--fg-color: var(--color-blue-dark);
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Back link component
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
@use 'sass:map';
|
|
6
|
+
@use '../abstracts/variables';
|
|
7
|
+
@use '../abstracts/mixins/breakpoints' as *;
|
|
8
|
+
@use '../abstracts/mixins/typography';
|
|
9
|
+
|
|
10
|
+
.pkt-back-link {
|
|
11
|
+
position: relative;
|
|
12
|
+
@include typography.get-text('pkt-txt-14-light');
|
|
13
|
+
padding: map.get(variables.$spacing, 'size-12')
|
|
14
|
+
map.get(variables.$spacing, 'size-16');
|
|
15
|
+
|
|
16
|
+
@include bp('laptop-up') {
|
|
17
|
+
padding: map.get(variables.$spacing, 'size-12')
|
|
18
|
+
map.get(variables.$spacing, 'size-64');
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
&__link {
|
|
22
|
+
display: flex;
|
|
23
|
+
align-items: center;
|
|
24
|
+
justify-content: flex-start;
|
|
25
|
+
gap: map.get(variables.$spacing, 'size-12');
|
|
26
|
+
text-decoration: none;
|
|
27
|
+
color: var(--color-blue-dark);
|
|
28
|
+
|
|
29
|
+
&:visited,
|
|
30
|
+
&:focus,
|
|
31
|
+
&:hover,
|
|
32
|
+
&:active {
|
|
33
|
+
color: var(--color-blue-dark);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
&:hover {
|
|
37
|
+
text-decoration: underline;
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
&__icon {
|
|
42
|
+
flex-basis: 1rem;
|
|
43
|
+
flex-shrink: 0;
|
|
44
|
+
padding-bottom: 4px;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
&__text {
|
|
48
|
+
flex-grow: 1;
|
|
49
|
+
}
|
|
50
|
+
}
|