@odx/ui 1.0.0-rc.1 → 1.0.0-rc.10

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.
Files changed (92) hide show
  1. package/323d385340fb9fee6450.svg +6 -0
  2. package/LICENSE +1 -0
  3. package/README.md +32 -0
  4. package/core-icons.css +39 -9
  5. package/core-icons.woff2 +0 -0
  6. package/core-theme.css +1 -1
  7. package/package.json +7 -8
  8. package/scss/{modules → abstract}/_breakpoints.scss +11 -11
  9. package/scss/{modules/_vertical-rythm.scss → abstract/_dimensions.scss} +29 -26
  10. package/scss/abstract/_index.scss +5 -0
  11. package/scss/abstract/_motion.scss +12 -0
  12. package/scss/abstract/_typography.scss +25 -0
  13. package/scss/abstract/_utils.scss +124 -0
  14. package/scss/cdk/active-indicator.scss +25 -0
  15. package/scss/cdk/connected-overlay.scss +36 -0
  16. package/scss/components/accordion-item.component.scss +56 -0
  17. package/scss/components/accordion.component.scss +3 -0
  18. package/scss/components/{action-group/action-group.component.scss → action-group.component.scss} +11 -7
  19. package/scss/components/{area-header/area-header.component.scss → area-header.component.scss} +33 -39
  20. package/scss/components/{avatar/avatar.component.scss → avatar.component.scss} +18 -13
  21. package/scss/components/{badge/badge.component.scss → badge.component.scss} +15 -24
  22. package/scss/components/bar.component.scss +86 -0
  23. package/scss/components/breadcrumbs.component.scss +26 -0
  24. package/scss/components/button-group.component.scss +99 -0
  25. package/scss/components/button.component.scss +129 -0
  26. package/scss/components/checkbox.component.scss +117 -0
  27. package/scss/components/chip.component.scss +52 -0
  28. package/scss/components/circular-progress.component.scss +75 -0
  29. package/scss/components/content-box.component.scss +54 -0
  30. package/scss/components/dropdown.component.scss +28 -0
  31. package/scss/components/form-field.component.scss +208 -0
  32. package/scss/components/header.component.scss +40 -0
  33. package/scss/components/icon.component.scss +35 -0
  34. package/scss/components/inline-message.component.scss +33 -0
  35. package/scss/components/launch-tile.component.scss +118 -0
  36. package/scss/components/{link/link.component.scss → link.component.scss} +6 -4
  37. package/scss/components/list-item.component.scss +107 -0
  38. package/scss/components/list.component.scss +3 -0
  39. package/scss/components/loading-spinner.component.scss +54 -0
  40. package/scss/components/{logo/logo.component.scss → logo.component.scss} +5 -4
  41. package/scss/components/main-menu-button.component.scss +7 -0
  42. package/scss/components/{main-menu/components/main-menu-item.component.scss → main-menu-item.component.scss} +14 -12
  43. package/scss/components/{main-menu/main-menu.component.scss → main-menu.component.scss} +37 -29
  44. package/scss/components/menu-item.component.scss +8 -0
  45. package/scss/components/menu.component.scss +16 -0
  46. package/scss/components/modal.component.scss +144 -0
  47. package/scss/components/progress.component.scss +41 -0
  48. package/scss/components/radio-button.component.scss +120 -0
  49. package/scss/components/radio-group.component.scss +14 -0
  50. package/scss/components/rail-navigation-item.component.scss +60 -0
  51. package/scss/components/rail-navigation.component.scss +32 -0
  52. package/scss/components/select.component.scss +103 -0
  53. package/scss/components/slider.component.scss +131 -0
  54. package/scss/components/spinbox.component.scss +124 -0
  55. package/scss/components/switch.component.scss +163 -0
  56. package/scss/components/tab-bar-item.component.scss +53 -0
  57. package/scss/components/tab-bar.component.scss +124 -0
  58. package/scss/components/toast-item.component.scss +79 -0
  59. package/scss/components/toast.component.scss +33 -0
  60. package/scss/components/toggle-button-group.component.scss +63 -0
  61. package/scss/components/toggle-button.component.scss +69 -0
  62. package/scss/components/tooltip.component.scss +34 -0
  63. package/scss/core.scss +66 -30
  64. package/scss/layout/_base.scss +35 -0
  65. package/scss/layout/_content.scss +25 -0
  66. package/scss/layout/_description-list.scss +30 -0
  67. package/scss/layout/_helpers.scss +85 -0
  68. package/scss/{modules → layout}/_layout.scss +96 -46
  69. package/scss/layout/_text-list.scss +18 -0
  70. package/scss/layout/_typography.scss +114 -0
  71. package/scss/{base/_reset.scss → reset.scss} +30 -5
  72. package/scss/variables/_color-palettes.scss +59 -55
  73. package/scss/variables/_colors.scss +15 -15
  74. package/scss/variables/_controls.scss +47 -0
  75. package/scss/variables/_index.scss +6 -0
  76. package/scss/variables/_typography.scss +18 -0
  77. package/scss/variables/_vertical-rythm.scss +3 -0
  78. package/scss/variables/_visuals.scss +15 -8
  79. package/scss/_helpers.scss +0 -15
  80. package/scss/base/_mixins.scss +0 -3
  81. package/scss/base/_utils.scss +0 -19
  82. package/scss/base/mixins/_container.scss +0 -31
  83. package/scss/base/mixins/_control.scss +0 -50
  84. package/scss/base/mixins/_transition.scss +0 -10
  85. package/scss/components/button/button.component.scss +0 -94
  86. package/scss/components/checkbox/checkbox.component.scss +0 -130
  87. package/scss/components/content-box/content-box.component.scss +0 -50
  88. package/scss/components/header/header.component.scss +0 -39
  89. package/scss/components/icon/icon.component.scss +0 -38
  90. package/scss/components/main-menu/components/main-menu-button.component.scss +0 -7
  91. package/scss/components/radio-group/_radio-group.component.scss +0 -145
  92. package/scss/modules/_typography.scss +0 -161
@@ -1,50 +0,0 @@
1
- @use '../../modules/breakpoints' as br;
2
- @use '../../modules/vertical-rythm' as vr;
3
-
4
- .odx-content-box {
5
- background-color: var(--odx-c-background-content);
6
- display: block;
7
-
8
- &__header,
9
- &__footer {
10
- align-items: center;
11
- display: flex;
12
- flex-wrap: wrap;
13
-
14
- > * {
15
- flex: 1 1 auto;
16
- }
17
- }
18
-
19
- &__header {
20
- @include vr.padding(1, ('top', 'right', 'left'));
21
- @include br.down(phone) {
22
- @include vr.padding(0.5, ('top', 'right', 'left'));
23
- }
24
- }
25
-
26
- &__footer {
27
- @include vr.padding(1, ('right', 'bottom', 'left'));
28
- @include br.down(phone) {
29
- @include vr.padding(0.5, ('right', 'bottom', 'left'));
30
- }
31
- }
32
-
33
- &__content {
34
- @include vr.padding(1);
35
- @include br.down(phone) {
36
- @include vr.padding(0.5);
37
- }
38
- }
39
-
40
- .odx-area-header ~ &__content {
41
- padding-top: 0;
42
- }
43
-
44
- .odx-area-header {
45
- @include vr.padding(1, ('top', 'bottom'));
46
- @include br.down(phone) {
47
- @include vr.padding(0.5, ('top', 'bottom'));
48
- }
49
- }
50
- }
@@ -1,39 +0,0 @@
1
- @use 'sass:math';
2
- @use '../../base/mixins' as mx;
3
- @use '../../modules/vertical-rythm' as vr;
4
- @use '../../modules/typography' as t;
5
-
6
- .odx-header {
7
- @include vr.padding(math.div(20, 24), 'left');
8
- @include vr.padding(0.5, 'right');
9
- @include vr.height(2);
10
- @include mx.vertical-center-content();
11
-
12
- background-color: var(--odx-c-background-content);
13
-
14
- .odx-main-menu-button {
15
- margin-left: vr.get-size(-1 * math.div(1, 3));
16
- margin-right: vr.get-size(0.5);
17
- }
18
-
19
- &__title,
20
- .odx-logo {
21
- margin-right: auto;
22
- }
23
-
24
- &__title {
25
- @extend .odx-title;
26
- @extend .odx-title--6;
27
- @include t.prevent-text-overflow();
28
- }
29
-
30
- .odx-action-group:not(:last-child) {
31
- border-right: 1px solid var(--odx-c-seperator);
32
- margin-right: vr.get-size(0.5);
33
- padding-right: vr.get-size(0.5);
34
- }
35
-
36
- &__title ~ .odx-logo {
37
- display: none;
38
- }
39
- }
@@ -1,38 +0,0 @@
1
- @use 'sass:math';
2
- @use '../../modules/vertical-rythm' as vr;
3
-
4
- $icon-sizes: (small math.div(2, 3) 1, large math.div(4, 3) 2);
5
-
6
- .odx-icon {
7
- @include vr.container(1);
8
-
9
- direction: ltr;
10
- display: inline-block;
11
- font-feature-settings: 'liga';
12
- font-size: vr.get-size(1);
13
- -moz-osx-font-smoothing: grayscale;
14
- -webkit-font-smoothing: antialiased;
15
- font-style: normal;
16
- font-weight: normal;
17
- letter-spacing: normal;
18
- line-height: 1;
19
- overflow: hidden;
20
- position: relative;
21
- text-rendering: auto;
22
- text-transform: none;
23
- white-space: nowrap;
24
-
25
- @each $size, $size_factor, $factor in $icon-sizes {
26
- &.odx-icon--#{$size} {
27
- @include vr.container($factor, $size_factor);
28
-
29
- font-size: vr.get-size($size_factor);
30
- }
31
- }
32
-
33
- &.odx-icon--inline {
34
- font-size: inherit;
35
- height: auto;
36
- width: auto;
37
- }
38
- }
@@ -1,7 +0,0 @@
1
- @use '../../button/button.component';
2
-
3
- .odx-main-menu-button {
4
- @extend .odx-button--ghost;
5
-
6
- color: var(--odx-c-control-text);
7
- }
@@ -1,145 +0,0 @@
1
- @use 'sass:math';
2
- @use '../../modules/vertical-rythm' as vr;
3
- @use '../../modules/typography' as t;
4
- @use '../../base/mixins' as mx;
5
-
6
- :root {
7
- --odx-radio-button-color: var(--odx-c-highlight-text);
8
- --odx-radio-button-color-disabled: var(--odx-c-control-text-disabled);
9
-
10
- --odx-radio-button-background-color: var(--odx-c-control);
11
- --odx-radio-button-background-color-active: var(--odx-c-highlight);
12
- --odx-radio-button-background-color-disabled: var(--odx-c-control-disabled);
13
- --odx-radio-button-background-color-readonly: var(--white);
14
-
15
- --odx-radio-button-border-color: var(--odx-c-control-disabled);
16
- --odx-radio-button-border-color-active: var(--odx-c-highlight);
17
- --odx-radio-button-border-color-hover: var(--odx-c-control-hover);
18
- --odx-radio-button-border-color-readonly: var(--odx-c-control-disabled);
19
-
20
- --odx-radio-button-label-color: var(--odx-c-text);
21
- --odx-radio-button-label-color-disabled: var(--odx-c-text-disabled);
22
- }
23
-
24
- .odx-radio-group {
25
- @include vr.padding-y(0.5);
26
-
27
- display: block;
28
-
29
- &--horizontal {
30
- column-gap: vr.get-size(0.5);
31
- display: flex;
32
- flex-wrap: wrap;
33
- }
34
- }
35
-
36
- .odx-radio-button {
37
- $root: &;
38
-
39
- color: var(--odx-radio-button-label-color);
40
- display: block;
41
-
42
- &.is-disabled,
43
- &.is-readonly {
44
- @include mx.non-interactive();
45
- }
46
-
47
- &.is-disabled {
48
- color: var(--odx-radio-button-label-color-disabled);
49
- }
50
-
51
- &__label {
52
- @include mx.interactive($focus-within: true);
53
- @include vr.line-height(1);
54
- @include mx.transition(background-color color outline);
55
- @include t.font-size(0);
56
-
57
- border-radius: var(--odx-v-border-radius-controls);
58
- border-radius: vr.get-size(0.5);
59
- border-bottom-right-radius: var(--odx-v-border-radius-controls);
60
- border-top-right-radius: var(--odx-v-border-radius-controls);
61
- color: inherit;
62
- cursor: pointer;
63
- display: inline-flex;
64
- min-height: vr.get-size(1);
65
- padding: 0 2px;
66
- vertical-align: top;
67
- }
68
-
69
- &__input {
70
- @include mx.visually-hidden();
71
- }
72
-
73
- &__indicator {
74
- @include vr.container(1, math.div(20, 24));
75
- @include mx.transition(background-color border-color);
76
- @include mx.center-content();
77
-
78
- background-color: var(--odx-radio-button-background-color);
79
- border: 1px solid var(--odx-radio-button-border-color);
80
- border-radius: 50%;
81
- box-sizing: border-box;
82
- color: var(--odx-radio-button-color);
83
- flex: 0 0 auto;
84
-
85
- &::before {
86
- @include mx.transition(transform);
87
- @include vr.container(math.div(4, 24));
88
-
89
- background-color: currentcolor;
90
- border-radius: 50%;
91
- content: '';
92
- transform: scale(0);
93
- }
94
-
95
- #{$root}:hover & {
96
- border-color: var(--odx-radio-button-border-color-hover);
97
- }
98
-
99
- #{$root}__input:checked ~ & {
100
- background-color: var(--odx-radio-button-background-color-active);
101
- border-color: var(--odx-radio-button-border-color-active);
102
- }
103
-
104
- #{$root}.has-error & {
105
- background-color: var(--odx-c-error);
106
- border-color: var(--odx-c-error-outline);
107
- color: var(--odx-c-error-text);
108
- }
109
-
110
- #{$root}.has-error:hover & {
111
- border-color: var(--odx-c-error-outline-hover);
112
- }
113
-
114
- #{$root}.is-disabled & {
115
- background-color: var(--odx-radio-button-background-color-disabled);
116
- border-color: transparent;
117
- color: var(--odx-radio-button-color-disabled);
118
- }
119
-
120
- #{$root}.is-readonly & {
121
- background-color: var(--odx-radio-button-background-color-readonly);
122
- border-color: var(--odx-radio-button-border-color-readonly);
123
- color: inherit;
124
- }
125
- }
126
-
127
- &__content {
128
- @include vr.margin(0.5, left);
129
-
130
- padding-left: 2px;
131
-
132
- &:empty {
133
- margin: 0;
134
- padding: 0;
135
- }
136
- }
137
-
138
- &__input:checked ~ .odx-radio-button__indicator::before {
139
- transform: scale(1);
140
- }
141
-
142
- &--no-label .odx-radio-button__label {
143
- border-radius: vr.get-size(0.5);
144
- }
145
- }
@@ -1,161 +0,0 @@
1
- /* stylelint-disable block-closing-brace-newline-after */
2
- @use 'sass:math';
3
- @use 'breakpoints' as br;
4
- @use 'vertical-rythm' as vr;
5
- @use '../base/utils' as utils;
6
-
7
- $base-size: 16px;
8
- $base-line-height: 1.5;
9
-
10
- @mixin font-size($size: 1) {
11
- @if math.round($size) != $size {
12
- @error '$size must me an integer';
13
- }
14
-
15
- @if $size < 0 {
16
- font-size: calc(var(--odx-t-base-size) * utils.css-pow(var(--odx-t-negative-font-scaling-factor), $size));
17
- } @else {
18
- font-size: calc(var(--odx-t-base-size) * utils.css-pow(var(--odx-t-positive-font-scaling-factor), $size));
19
- }
20
- }
21
-
22
- @mixin prevent-text-overflow() {
23
- overflow: hidden;
24
- text-overflow: ellipsis;
25
- white-space: nowrap;
26
- }
27
-
28
- :root {
29
- --odx-t-base-size: #{$base-size};
30
- --odx-t-base-line-height: #{$base-line-height};
31
- --odx-t-font-weight-normal: normal;
32
- --odx-t-font-weight-medium: 500;
33
- --odx-t-font-weight-bold: bold;
34
- --odx-t-positive-font-scaling-factor: 1.125;
35
- --odx-t-negative-font-scaling-factor: 1.2;
36
-
37
- @include br.up(tablet) {
38
- --odx-t-positive-font-scaling-factor: 1.25;
39
- }
40
- }
41
-
42
- @font-face {
43
- font-family: Pangea;
44
- font-style: normal;
45
- font-weight: normal;
46
- src: url('../assets/fonts/PangeaText-RegularWeb.woff2') format('woff2');
47
- }
48
-
49
- @font-face {
50
- font-family: Pangea;
51
- font-style: normal;
52
- font-weight: 500;
53
- src: url('../assets/fonts/PangeaText-MediumWeb.woff2') format('woff2');
54
- }
55
-
56
- @font-face {
57
- font-family: Pangea;
58
- font-style: normal;
59
- font-weight: bold;
60
- src: url('../assets/fonts/PangeaText-SemiBoldWeb.woff2') format('woff2');
61
- }
62
-
63
- html body {
64
- @include font-size(0);
65
- @include vr.line-height(1);
66
-
67
- color: var(--odx-c-text);
68
- font-family: Pangea, sans-serif;
69
- font-weight: var(--odx-t-font-weight-normal);
70
- }
71
-
72
- h1,
73
- h2,
74
- h3,
75
- h4,
76
- h5,
77
- h6,
78
- .odx-title,
79
- .odx-subtitle {
80
- color: var(--odx-c-headline);
81
- font-weight: var(--odx-t-font-weight-bold);
82
- }
83
-
84
- .odx-subtitle {
85
- font-weight: var(--odx-t-font-weight-normal);
86
- }
87
-
88
- h1,
89
- .odx-title--1 {
90
- @include font-size(5);
91
- @include vr.line-height(2, math.div(40, 24));
92
-
93
- @include br.up(tablet) {
94
- @include vr.line-height(3, math.div(64, 24));
95
- }
96
- }
97
-
98
- h2,
99
- .odx-title--2 {
100
- @include font-size(4);
101
- @include vr.line-height(2, 1.5);
102
-
103
- @include br.up(tablet) {
104
- @include vr.line-height(3, math.div(54, 24));
105
- }
106
- }
107
-
108
- h3,
109
- .odx-title--3 {
110
- @include font-size(3);
111
- @include vr.line-height(2, math.div(32, 24));
112
-
113
- @include br.up(tablet) {
114
- @include vr.line-height(2, math.div(42, 24));
115
- }
116
- }
117
-
118
- h4,
119
- .odx-title--4 {
120
- @include font-size(2);
121
- @include vr.line-height(2, math.div(30, 24));
122
- }
123
-
124
- h5,
125
- .odx-title--5 {
126
- @include font-size(1);
127
- @include vr.line-height(1);
128
- }
129
-
130
- h6,
131
- .odx-title--6 {
132
- @include font-size(0);
133
- @include vr.line-height(1);
134
- }
135
-
136
- p,
137
- .odx-text {
138
- @include vr.line-height(1);
139
-
140
- font-weight: var(--odx-t-font-weight-normal);
141
-
142
- &--small {
143
- @include font-size(-1);
144
- @include vr.line-height(1, math.div(20, 24));
145
- }
146
-
147
- &--xsmall {
148
- @include font-size(-2);
149
- @include vr.line-height(1, math.div(16, 24));
150
- }
151
- }
152
-
153
- .odx-fs-normal {
154
- font-weight: var(--odx-t-font-weight-normal);
155
- }
156
-
157
- b,
158
- strong,
159
- .odx-fs-bold {
160
- font-weight: var(--odx-t-font-weight-bold);
161
- }