@odx/ui 1.0.0-rc.1 → 1.0.0-rc.3
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/323d385340fb9fee6450.svg +6 -0
- package/LICENSE +1 -0
- package/README.md +32 -0
- package/core-icons.css +37 -9
- package/core-icons.woff2 +0 -0
- package/core-theme.css +1 -1
- package/package.json +7 -8
- package/scss/{modules → abstract}/_breakpoints.scss +11 -11
- package/scss/{modules/_vertical-rythm.scss → abstract/_dimensions.scss} +28 -26
- package/scss/abstract/_index.scss +5 -0
- package/scss/abstract/_motion.scss +10 -0
- package/scss/abstract/_typography.scss +25 -0
- package/scss/abstract/_utils.scss +114 -0
- package/scss/components/accordion-item.component.scss +59 -0
- package/scss/components/accordion.component.scss +3 -0
- package/scss/components/{action-group/action-group.component.scss → action-group.component.scss} +10 -6
- package/scss/components/{area-header/area-header.component.scss → area-header.component.scss} +28 -27
- package/scss/components/{avatar/avatar.component.scss → avatar.component.scss} +13 -13
- package/scss/components/{badge/badge.component.scss → badge.component.scss} +10 -10
- package/scss/components/button-group.component.scss +98 -0
- package/scss/components/button.component.scss +123 -0
- package/scss/components/checkbox.component.scss +116 -0
- package/scss/components/content-box.component.scss +50 -0
- package/scss/components/form-field.component.scss +204 -0
- package/scss/components/header.component.scss +40 -0
- package/scss/components/icon.component.scss +35 -0
- package/scss/components/{link/link.component.scss → link.component.scss} +6 -4
- package/scss/components/{logo/logo.component.scss → logo.component.scss} +5 -4
- package/scss/components/main-menu-button.component.scss +7 -0
- package/scss/components/{main-menu/components/main-menu-item.component.scss → main-menu-item.component.scss} +13 -12
- package/scss/components/{main-menu/main-menu.component.scss → main-menu.component.scss} +35 -28
- package/scss/components/modal.component.scss +85 -0
- package/scss/components/radio-button.component.scss +120 -0
- package/scss/components/radio-group.component.scss +14 -0
- package/scss/components/switch.component.scss +163 -0
- package/scss/components/toggle-button-group.component.scss +25 -0
- package/scss/components/toggle-button.component.scss +55 -0
- package/scss/core.scss +34 -30
- package/scss/layout/_base.scss +29 -0
- package/scss/layout/_helpers.scss +95 -0
- package/scss/{modules → layout}/_layout.scss +96 -46
- package/scss/layout/_typography.scss +117 -0
- package/scss/{base/_reset.scss → reset.scss} +25 -5
- package/scss/variables/_color-palettes.scss +57 -54
- package/scss/variables/_colors.scss +12 -15
- package/scss/variables/_controls.scss +48 -0
- package/scss/variables/_index.scss +6 -0
- package/scss/variables/_typography.scss +18 -0
- package/scss/variables/_vertical-rythm.scss +3 -0
- package/scss/variables/_visuals.scss +12 -7
- package/scss/_helpers.scss +0 -15
- package/scss/base/_mixins.scss +0 -3
- package/scss/base/_utils.scss +0 -19
- package/scss/base/mixins/_container.scss +0 -31
- package/scss/base/mixins/_control.scss +0 -50
- package/scss/base/mixins/_transition.scss +0 -10
- package/scss/components/button/button.component.scss +0 -94
- package/scss/components/checkbox/checkbox.component.scss +0 -130
- package/scss/components/content-box/content-box.component.scss +0 -50
- package/scss/components/header/header.component.scss +0 -39
- package/scss/components/icon/icon.component.scss +0 -38
- package/scss/components/main-menu/components/main-menu-button.component.scss +0 -7
- package/scss/components/radio-group/_radio-group.component.scss +0 -145
- package/scss/modules/_typography.scss +0 -161
|
@@ -1,9 +1,26 @@
|
|
|
1
1
|
@use 'sass:math';
|
|
2
2
|
|
|
3
|
+
@function _get-line-height-factor($factor, $line-height-factor) {
|
|
4
|
+
@if $line-height-factor == null {
|
|
5
|
+
@return $factor;
|
|
6
|
+
}
|
|
7
|
+
@return $line-height-factor;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
@mixin _vertical-rythm-dimension($factor, $line-height-factor, $properties) {
|
|
11
|
+
$line-height-factor: _get-line-height-factor($factor, $line-height-factor);
|
|
12
|
+
|
|
13
|
+
@include margin-y(calc(($factor - $line-height-factor) / 2));
|
|
14
|
+
|
|
15
|
+
@each $property in $properties {
|
|
16
|
+
#{$property}: get-size($line-height-factor);
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
3
20
|
@function get-size($factor) {
|
|
4
21
|
$factor: math.div(math.ceil($factor * 1e4), 1e4);
|
|
5
22
|
|
|
6
|
-
@return calc(var(--odx-
|
|
23
|
+
@return calc(var(--odx-vertical-rythm-base-size) * $factor);
|
|
7
24
|
}
|
|
8
25
|
|
|
9
26
|
@mixin margin($factor, $directions: ('top', 'right', 'bottom', 'left')) {
|
|
@@ -13,13 +30,13 @@
|
|
|
13
30
|
}
|
|
14
31
|
|
|
15
32
|
@mixin margin-x($factor: 1) {
|
|
16
|
-
$spacing: calc(var(--odx-
|
|
33
|
+
$spacing: calc(var(--odx-vertical-rythm-base-size) * $factor);
|
|
17
34
|
|
|
18
35
|
@include margin($factor, ('right', 'left'));
|
|
19
36
|
}
|
|
20
37
|
|
|
21
38
|
@mixin margin-y($factor: 1) {
|
|
22
|
-
$spacing: calc(var(--odx-
|
|
39
|
+
$spacing: calc(var(--odx-vertical-rythm-base-size) * $factor);
|
|
23
40
|
|
|
24
41
|
@include margin($factor, ('top', 'bottom'));
|
|
25
42
|
}
|
|
@@ -31,48 +48,33 @@
|
|
|
31
48
|
}
|
|
32
49
|
|
|
33
50
|
@mixin padding-x($factor: 1) {
|
|
34
|
-
$spacing: calc(var(--odx-
|
|
51
|
+
$spacing: calc(var(--odx-vertical-rythm-base-size) * $factor);
|
|
35
52
|
|
|
36
53
|
@include padding($factor, ('right', 'left'));
|
|
37
54
|
}
|
|
38
55
|
|
|
39
56
|
@mixin padding-y($factor: 1) {
|
|
40
|
-
$spacing: calc(var(--odx-
|
|
57
|
+
$spacing: calc(var(--odx-vertical-rythm-base-size) * $factor);
|
|
41
58
|
|
|
42
59
|
@include padding($factor, ('top', 'bottom'));
|
|
43
60
|
}
|
|
44
61
|
|
|
45
62
|
@mixin container($factor: 1, $line-height-factor: null) {
|
|
46
|
-
@
|
|
47
|
-
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
@include margin-y(calc(($factor - $line-height-factor) / 2));
|
|
63
|
+
@include _vertical-rythm-dimension($factor, $line-height-factor, (height, width));
|
|
64
|
+
}
|
|
51
65
|
|
|
52
|
-
|
|
53
|
-
|
|
66
|
+
@mixin min-height($factor: 1, $line-height-factor: null) {
|
|
67
|
+
@include _vertical-rythm-dimension($factor, $line-height-factor, min-height);
|
|
54
68
|
}
|
|
55
69
|
|
|
56
70
|
@mixin height($factor: 1, $line-height-factor: null) {
|
|
57
|
-
@
|
|
58
|
-
$line-height-factor: $factor;
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
@include margin-y(calc(($factor - $line-height-factor) / 2));
|
|
62
|
-
|
|
63
|
-
height: get-size($line-height-factor);
|
|
71
|
+
@include _vertical-rythm-dimension($factor, $line-height-factor, height);
|
|
64
72
|
}
|
|
65
73
|
|
|
66
74
|
@mixin line-height($factor: 1, $line-height-factor: null) {
|
|
67
|
-
|
|
68
|
-
$line-height-factor: $factor;
|
|
69
|
-
}
|
|
75
|
+
$line-height-factor: _get-line-height-factor($factor, $line-height-factor);
|
|
70
76
|
|
|
71
77
|
@include padding-y(calc(($factor - $line-height-factor) / 2));
|
|
72
78
|
|
|
73
79
|
line-height: get-size($line-height-factor);
|
|
74
80
|
}
|
|
75
|
-
|
|
76
|
-
:root {
|
|
77
|
-
--odx-vr-base-size: calc(var(--odx-t-base-line-height) * var(--odx-t-base-size));
|
|
78
|
-
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
@mixin transition($properties, $duration: var(--odx-v-transition-duration), $delay: 0ms) {
|
|
2
|
+
$props: ();
|
|
3
|
+
|
|
4
|
+
@each $prop in $properties {
|
|
5
|
+
$props: append($props, $prop, comma);
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
transition: all $duration $delay var(--odx-v-transition-easing-fn);
|
|
9
|
+
transition-property: $props;
|
|
10
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
@use 'sass:math';
|
|
2
|
+
@use 'utils';
|
|
3
|
+
|
|
4
|
+
@mixin font-size($size: 1) {
|
|
5
|
+
@if math.round($size) != $size {
|
|
6
|
+
@error '$size must me an integer';
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
@if $size < 0 {
|
|
10
|
+
font-size: calc(var(--odx-typography-base-size) * utils.css-pow(var(--odx-typography-negative-font-scaling-factor), $size));
|
|
11
|
+
} @else {
|
|
12
|
+
font-size: calc(var(--odx-typography-base-size) * utils.css-pow(var(--odx-typography-positive-font-scaling-factor), $size));
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
@mixin font-weight($value: normal) {
|
|
17
|
+
font-weight: var(--odx-typography-font-weight-#{$value});
|
|
18
|
+
letter-spacing: var(--odx-typography-font-weight-#{$value}-letter-spacing);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
@mixin prevent-text-overflow() {
|
|
22
|
+
overflow: hidden;
|
|
23
|
+
text-overflow: ellipsis;
|
|
24
|
+
white-space: nowrap;
|
|
25
|
+
}
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
@use 'sass:math';
|
|
2
|
+
|
|
3
|
+
@function css-pow($value, $exponent) {
|
|
4
|
+
$css-value: 1;
|
|
5
|
+
|
|
6
|
+
@if $exponent < 0 {
|
|
7
|
+
@for $i from 1 through math.abs($exponent) {
|
|
8
|
+
$css-value: $css-value + '*1/#{$value}';
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
@if $exponent > 0 {
|
|
13
|
+
@for $i from 1 through $exponent {
|
|
14
|
+
$css-value: $css-value + '*#{$value}';
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
@return calc(#{$css-value});
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
@mixin center-content($inline: false) {
|
|
22
|
+
@if $inline {
|
|
23
|
+
display: inline-flex;
|
|
24
|
+
} @else {
|
|
25
|
+
display: flex;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
align-items: center;
|
|
29
|
+
justify-content: center;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
@mixin vertical-center-content($inline: false) {
|
|
33
|
+
@if $inline {
|
|
34
|
+
display: inline-flex;
|
|
35
|
+
} @else {
|
|
36
|
+
display: flex;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
align-items: center;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
@mixin horizontal-center-content($inline: false) {
|
|
43
|
+
@if $inline {
|
|
44
|
+
display: inline-flex;
|
|
45
|
+
} @else {
|
|
46
|
+
display: flex;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
justify-content: center;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
@mixin visually-hidden() {
|
|
53
|
+
appearance: none;
|
|
54
|
+
height: 0;
|
|
55
|
+
margin: 0;
|
|
56
|
+
opacity: 0;
|
|
57
|
+
outline: none !important;
|
|
58
|
+
padding: 0;
|
|
59
|
+
position: absolute;
|
|
60
|
+
width: 0;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
@mixin _focus-styles($with-background) {
|
|
64
|
+
outline-color: var(--odx-c-focus-outline);
|
|
65
|
+
@if $with-background {
|
|
66
|
+
&,
|
|
67
|
+
&:hover {
|
|
68
|
+
background-color: var(--odx-c-focus);
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
@mixin focus-state($with-background: true, $focus-within: false, $focus-within-selector: null) {
|
|
74
|
+
@if $focus-within {
|
|
75
|
+
@if $focus-within-selector {
|
|
76
|
+
$focus-within-selector: '#{$focus-within-selector}:focus-visible';
|
|
77
|
+
} @else {
|
|
78
|
+
$focus-within-selector: ':focus-visible';
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
&:focus-within:has(#{$focus-within-selector}) {
|
|
82
|
+
@include _focus-styles($with-background);
|
|
83
|
+
@content;
|
|
84
|
+
}
|
|
85
|
+
} @else {
|
|
86
|
+
&:focus-visible {
|
|
87
|
+
@include _focus-styles($with-background);
|
|
88
|
+
@content;
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
@mixin with-outline {
|
|
94
|
+
outline: var(--odx-v-outline);
|
|
95
|
+
outline-offset: var(--odx-v-outline-offset);
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
@mixin interactive($with-background: true, $focus-within: false) {
|
|
99
|
+
@include with-outline;
|
|
100
|
+
@include focus-state($with-background, $focus-within);
|
|
101
|
+
|
|
102
|
+
cursor: pointer;
|
|
103
|
+
user-select: none;
|
|
104
|
+
|
|
105
|
+
&:disabled,
|
|
106
|
+
&.is-disabled {
|
|
107
|
+
@include non-interactive();
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
@mixin non-interactive() {
|
|
112
|
+
pointer-events: none;
|
|
113
|
+
user-select: none;
|
|
114
|
+
}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
@use 'sass:math';
|
|
2
|
+
@use '../abstract/dimensions';
|
|
3
|
+
@use '../abstract/motion';
|
|
4
|
+
@use '../abstract/typography';
|
|
5
|
+
@use '../abstract/utils';
|
|
6
|
+
|
|
7
|
+
.odx-accordion-item {
|
|
8
|
+
$root: &;
|
|
9
|
+
|
|
10
|
+
@include dimensions.padding(math.div(1, 6), 'bottom');
|
|
11
|
+
|
|
12
|
+
border-bottom: 1px solid var(--odx-input-control-outline-color);
|
|
13
|
+
display: block;
|
|
14
|
+
|
|
15
|
+
&:not(:last-child) {
|
|
16
|
+
@include dimensions.margin(1, 'bottom');
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
&__panel {
|
|
20
|
+
@include dimensions.padding-x(math.div(4, 24));
|
|
21
|
+
@include dimensions.line-height(1.5, 1);
|
|
22
|
+
@include motion.transition(background-color outline-color);
|
|
23
|
+
@include utils.interactive(true);
|
|
24
|
+
|
|
25
|
+
border-radius: var(--odx-v-border-radius-controls);
|
|
26
|
+
display: grid;
|
|
27
|
+
grid-template-columns: 1fr auto;
|
|
28
|
+
|
|
29
|
+
&:hover {
|
|
30
|
+
background-color: var(--blue-700-5);
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
#{$root}--expanded & {
|
|
34
|
+
@include typography.font-weight(medium);
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
&__icon {
|
|
39
|
+
@include motion.transition(transform);
|
|
40
|
+
|
|
41
|
+
transform: rotate(0deg);
|
|
42
|
+
|
|
43
|
+
#{$root}--expanded & {
|
|
44
|
+
transform: rotateX(180deg);
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
&__slot {
|
|
49
|
+
@include dimensions.padding-x(math.div(4, 24));
|
|
50
|
+
@include dimensions.padding-y(math.div(8, 24));
|
|
51
|
+
|
|
52
|
+
overflow: hidden;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
&.is-disabled {
|
|
56
|
+
color: var(--odx-c-text-disabled);
|
|
57
|
+
pointer-events: none;
|
|
58
|
+
}
|
|
59
|
+
}
|
package/scss/components/{action-group/action-group.component.scss → action-group.component.scss}
RENAMED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
@use '
|
|
2
|
-
@use '
|
|
3
|
-
@use '
|
|
1
|
+
@use '../abstract/dimensions';
|
|
2
|
+
@use '../abstract/utils';
|
|
3
|
+
@use 'button.component';
|
|
4
4
|
|
|
5
5
|
.odx-action-group {
|
|
6
|
-
@include
|
|
7
|
-
@include
|
|
6
|
+
@include dimensions.height(2, 1.5);
|
|
7
|
+
@include utils.vertical-center-content(true);
|
|
8
8
|
|
|
9
|
-
gap:
|
|
9
|
+
gap: dimensions.get-size(0.25);
|
|
10
10
|
|
|
11
11
|
&--reverse {
|
|
12
12
|
flex-direction: row-reverse;
|
|
@@ -18,6 +18,10 @@
|
|
|
18
18
|
|
|
19
19
|
color: var(--odx-c-control-text);
|
|
20
20
|
|
|
21
|
+
&:hover {
|
|
22
|
+
color: var(--odx-c-control-text);
|
|
23
|
+
}
|
|
24
|
+
|
|
21
25
|
&:focus-visible {
|
|
22
26
|
outline-color: var(--odx-c-focus-outline);
|
|
23
27
|
}
|
package/scss/components/{area-header/area-header.component.scss → area-header.component.scss}
RENAMED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
@use 'sass:math';
|
|
2
|
-
@use '
|
|
3
|
-
@use '
|
|
4
|
-
@use '
|
|
5
|
-
@use '../
|
|
6
|
-
@use '
|
|
2
|
+
@use '../abstract/breakpoints';
|
|
3
|
+
@use '../abstract/dimensions';
|
|
4
|
+
@use '../abstract/utils';
|
|
5
|
+
@use '../abstract/typography';
|
|
6
|
+
@use 'avatar.component';
|
|
7
|
+
@use '../layout/typography' as *;
|
|
7
8
|
|
|
8
9
|
:root {
|
|
9
10
|
--odx-area-header-title-color: var(--odx-c-headline);
|
|
@@ -11,11 +12,11 @@
|
|
|
11
12
|
}
|
|
12
13
|
|
|
13
14
|
.odx-area-header {
|
|
14
|
-
@include
|
|
15
|
+
@include dimensions.padding-x(1);
|
|
15
16
|
|
|
16
17
|
&,
|
|
17
18
|
&__container {
|
|
18
|
-
column-gap:
|
|
19
|
+
column-gap: dimensions.get-size(math.div(20, 24));
|
|
19
20
|
display: flex;
|
|
20
21
|
}
|
|
21
22
|
|
|
@@ -27,7 +28,7 @@
|
|
|
27
28
|
&__inner,
|
|
28
29
|
&__title,
|
|
29
30
|
&__subtitle {
|
|
30
|
-
@include
|
|
31
|
+
@include typography.prevent-text-overflow();
|
|
31
32
|
}
|
|
32
33
|
|
|
33
34
|
&__title,
|
|
@@ -65,10 +66,10 @@
|
|
|
65
66
|
}
|
|
66
67
|
|
|
67
68
|
&__content {
|
|
68
|
-
@include
|
|
69
|
+
@include utils.vertical-center-content();
|
|
69
70
|
|
|
70
71
|
flex-wrap: wrap;
|
|
71
|
-
min-height:
|
|
72
|
+
min-height: dimensions.get-size(2);
|
|
72
73
|
}
|
|
73
74
|
|
|
74
75
|
&--small,
|
|
@@ -84,7 +85,7 @@
|
|
|
84
85
|
|
|
85
86
|
&--large,
|
|
86
87
|
&--xlarge {
|
|
87
|
-
@include
|
|
88
|
+
@include breakpoints.down(tablet) {
|
|
88
89
|
flex-wrap: wrap;
|
|
89
90
|
|
|
90
91
|
.odx-area-header__content {
|
|
@@ -95,8 +96,8 @@
|
|
|
95
96
|
}
|
|
96
97
|
|
|
97
98
|
&--medium {
|
|
98
|
-
@include
|
|
99
|
-
@include
|
|
99
|
+
@include breakpoints.up(tablet) {
|
|
100
|
+
@include dimensions.padding-y(0.5);
|
|
100
101
|
}
|
|
101
102
|
|
|
102
103
|
.odx-area-header__title {
|
|
@@ -105,17 +106,17 @@
|
|
|
105
106
|
}
|
|
106
107
|
|
|
107
108
|
&--large {
|
|
108
|
-
@include
|
|
109
|
+
@include dimensions.padding-y(0.25);
|
|
109
110
|
|
|
110
|
-
@include
|
|
111
|
-
@include
|
|
111
|
+
@include breakpoints.up(tablet) {
|
|
112
|
+
@include dimensions.padding-y(0.5);
|
|
112
113
|
}
|
|
113
114
|
|
|
114
115
|
.odx-area-header__title {
|
|
115
116
|
@extend .odx-title--4;
|
|
116
117
|
|
|
117
|
-
@include
|
|
118
|
-
@include
|
|
118
|
+
@include breakpoints.down(tablet) {
|
|
119
|
+
@include dimensions.line-height(1);
|
|
119
120
|
}
|
|
120
121
|
}
|
|
121
122
|
|
|
@@ -125,15 +126,15 @@
|
|
|
125
126
|
}
|
|
126
127
|
|
|
127
128
|
&--xlarge {
|
|
128
|
-
@include
|
|
129
|
+
@include dimensions.padding-y(0.5);
|
|
129
130
|
|
|
130
|
-
@include
|
|
131
|
-
@include
|
|
131
|
+
@include breakpoints.up(tablet) {
|
|
132
|
+
@include dimensions.padding-y(1);
|
|
132
133
|
|
|
133
|
-
gap:
|
|
134
|
+
gap: dimensions.get-size(1);
|
|
134
135
|
|
|
135
136
|
.odx-area-header__container {
|
|
136
|
-
@include
|
|
137
|
+
@include dimensions.padding(1, top);
|
|
137
138
|
}
|
|
138
139
|
}
|
|
139
140
|
|
|
@@ -148,16 +149,16 @@
|
|
|
148
149
|
.odx-avatar {
|
|
149
150
|
@extend .odx-avatar--large;
|
|
150
151
|
|
|
151
|
-
@include
|
|
152
|
-
@include
|
|
152
|
+
@include breakpoints.up(tablet) {
|
|
153
|
+
@include dimensions.margin(-0.5, top);
|
|
153
154
|
}
|
|
154
155
|
}
|
|
155
156
|
|
|
156
157
|
.odx-area-header__content {
|
|
157
158
|
align-self: flex-end;
|
|
158
159
|
|
|
159
|
-
@include
|
|
160
|
-
@include
|
|
160
|
+
@include breakpoints.up(tablet) {
|
|
161
|
+
@include dimensions.margin(-0.5, bottom);
|
|
161
162
|
}
|
|
162
163
|
}
|
|
163
164
|
}
|
|
@@ -1,29 +1,29 @@
|
|
|
1
1
|
@use 'sass:math';
|
|
2
|
-
@use '
|
|
3
|
-
@use '
|
|
4
|
-
@use '
|
|
5
|
-
@use '
|
|
2
|
+
@use '../abstract/breakpoints';
|
|
3
|
+
@use '../abstract/dimensions';
|
|
4
|
+
@use '../abstract/utils';
|
|
5
|
+
@use '../abstract/typography';
|
|
6
6
|
|
|
7
7
|
@mixin avatar-size($size-factor, $line-height-factor, $font-size, $icon-factor) {
|
|
8
|
-
@include
|
|
9
|
-
@include
|
|
8
|
+
@include dimensions.container($size-factor, $line-height-factor);
|
|
9
|
+
@include typography.font-size($font-size);
|
|
10
10
|
|
|
11
11
|
> .odx-icon,
|
|
12
12
|
> .odx-icon[class*='odx-icon--'] {
|
|
13
|
-
@include
|
|
13
|
+
@include dimensions.container($icon-factor);
|
|
14
14
|
|
|
15
|
-
font-size:
|
|
15
|
+
font-size: dimensions.get-size($icon-factor);
|
|
16
16
|
}
|
|
17
17
|
}
|
|
18
18
|
|
|
19
19
|
.odx-avatar {
|
|
20
|
-
@include
|
|
21
|
-
@include
|
|
20
|
+
@include utils.center-content(true);
|
|
21
|
+
@include typography.font-weight(medium);
|
|
22
|
+
@include typography.prevent-text-overflow();
|
|
22
23
|
|
|
23
24
|
background-color: var(--blue-700-10);
|
|
24
25
|
border-radius: 50%;
|
|
25
26
|
color: var(--odx-c-text);
|
|
26
|
-
font-weight: var(--odx-t-font-weight-medium);
|
|
27
27
|
position: relative;
|
|
28
28
|
vertical-align: middle;
|
|
29
29
|
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
&--medium {
|
|
35
35
|
@include avatar-size(2, 1.5, 0, 1);
|
|
36
36
|
|
|
37
|
-
@include
|
|
37
|
+
@include breakpoints.up(tablet) {
|
|
38
38
|
@include avatar-size(3, math.div(64, 24), 2, 1.5);
|
|
39
39
|
}
|
|
40
40
|
}
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
&--large {
|
|
43
43
|
@include avatar-size(3, math.div(64, 24), 2, 1.5);
|
|
44
44
|
|
|
45
|
-
@include
|
|
45
|
+
@include breakpoints.up(tablet) {
|
|
46
46
|
@include avatar-size(4, 4, 4, 2.25);
|
|
47
47
|
}
|
|
48
48
|
}
|
|
@@ -1,28 +1,28 @@
|
|
|
1
1
|
@use 'sass:math';
|
|
2
|
-
@use '
|
|
3
|
-
@use '
|
|
4
|
-
@use '
|
|
2
|
+
@use '../abstract/dimensions';
|
|
3
|
+
@use '../abstract/utils';
|
|
4
|
+
@use '../abstract/typography';
|
|
5
5
|
|
|
6
6
|
:root {
|
|
7
7
|
--odx-badge-contrast-color: var(--odx-c-background-content);
|
|
8
8
|
}
|
|
9
9
|
|
|
10
10
|
.odx-badge {
|
|
11
|
-
$badge-size:
|
|
11
|
+
$badge-size: dimensions.get-size(math.div(2, 3));
|
|
12
12
|
|
|
13
|
-
@include
|
|
14
|
-
@include
|
|
15
|
-
@include
|
|
16
|
-
@include
|
|
13
|
+
@include dimensions.padding-x(math.div(1, 8));
|
|
14
|
+
@include utils.center-content(true);
|
|
15
|
+
@include utils.non-interactive();
|
|
16
|
+
@include typography.font-size(-2);
|
|
17
|
+
@include typography.font-weight(medium);
|
|
17
18
|
|
|
18
19
|
border-radius: $badge-size;
|
|
19
|
-
box-sizing: border-box;
|
|
20
|
-
font-weight: var(--odx-t-font-weight-medium);
|
|
21
20
|
height: $badge-size;
|
|
22
21
|
left: 0;
|
|
23
22
|
min-width: $badge-size;
|
|
24
23
|
outline: 1px solid transparent;
|
|
25
24
|
top: 0;
|
|
25
|
+
vertical-align: middle;
|
|
26
26
|
z-index: 9999;
|
|
27
27
|
|
|
28
28
|
&::before {
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
@use 'sass:math';
|
|
2
|
+
@use '../abstract/dimensions';
|
|
3
|
+
|
|
4
|
+
@mixin buttons-radius($vertical: false, $reversed: false) {
|
|
5
|
+
$start: 'first';
|
|
6
|
+
$end: 'last';
|
|
7
|
+
@if $reversed {
|
|
8
|
+
$start: 'last';
|
|
9
|
+
$end: 'first';
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
@if $vertical {
|
|
13
|
+
margin: 0;
|
|
14
|
+
|
|
15
|
+
&:#{$start}-child {
|
|
16
|
+
border-bottom-left-radius: 0;
|
|
17
|
+
border-bottom-right-radius: 0;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
&:#{$end}-child {
|
|
21
|
+
border-top-left-radius: 0;
|
|
22
|
+
border-top-right-radius: 0;
|
|
23
|
+
}
|
|
24
|
+
} @else {
|
|
25
|
+
&:#{$start}-child {
|
|
26
|
+
border-bottom-right-radius: 0;
|
|
27
|
+
border-top-right-radius: 0;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
&:#{$end}-child {
|
|
31
|
+
border-bottom-left-radius: 0;
|
|
32
|
+
border-top-left-radius: 0;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
&:not(:first-child, :last-child) {
|
|
37
|
+
border-radius: 0;
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.odx-button-group {
|
|
42
|
+
display: inline-flex;
|
|
43
|
+
flex-wrap: wrap;
|
|
44
|
+
gap: dimensions.get-size(math.div(2, 24));
|
|
45
|
+
|
|
46
|
+
&--reverse {
|
|
47
|
+
flex-direction: row-reverse;
|
|
48
|
+
justify-content: flex-end;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
&--reverse#{&}--vertical#{&}--block {
|
|
52
|
+
flex-direction: column-reverse;
|
|
53
|
+
justify-content: flex-end;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
&--block {
|
|
57
|
+
display: flex;
|
|
58
|
+
width: 100%;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
&:not(#{&}--vertical)#{&}--align-right {
|
|
62
|
+
justify-content: flex-end;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
&:not(#{&}--vertical)#{&}--align-right#{&}--reverse {
|
|
66
|
+
justify-content: flex-start;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
&:not(#{&}--vertical, #{&}--reverse) .odx-button {
|
|
70
|
+
@include buttons-radius();
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
&:not(#{&}--vertical)#{&}--reverse .odx-button {
|
|
74
|
+
@include buttons-radius(false, true);
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
&--vertical {
|
|
78
|
+
@include dimensions.margin-y(math.div(10, 24));
|
|
79
|
+
|
|
80
|
+
flex-direction: column;
|
|
81
|
+
|
|
82
|
+
.odx-button {
|
|
83
|
+
@include dimensions.height(math.div(35, 24));
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
&:not(#{&}--reverse)#{&}--vertical {
|
|
88
|
+
.odx-button {
|
|
89
|
+
@include buttons-radius(true);
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
&#{&}--reverse#{&}--vertical {
|
|
94
|
+
.odx-button {
|
|
95
|
+
@include buttons-radius(true, true);
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
}
|