ode-bootstrap 1.3.7-develop.202407101430 → 1.3.8-develop-mozo.202408081713

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/dist/version.txt CHANGED
@@ -1 +1 @@
1
- ode-bootstrap 10/07/2024 14:30:42
1
+ ode-bootstrap 08/08/2024 17:13:32
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ode-bootstrap",
3
- "version": "1.3.7-develop.202407101430",
3
+ "version": "1.3.8-develop-mozo.202408081713",
4
4
  "description": "Open Digital Education CSS framework based on bootstrap",
5
5
  "repository": {
6
6
  "type": "git",
@@ -17,6 +17,7 @@
17
17
  @import "form-text";
18
18
  @import "loading-screen";
19
19
  @import "media-library";
20
+ @import "help";
20
21
  @import "input-group";
21
22
  @import "image-picker";
22
23
  @import "modal";
@@ -0,0 +1,82 @@
1
+ #help-modal {
2
+ .section {
3
+ grid-row: 1 / 1;
4
+ grid-column: 2 / 2;
5
+ background: #fff;
6
+
7
+ &:target {
8
+ display: block !important;
9
+ }
10
+ }
11
+
12
+ .modal-body {
13
+ padding-top: $spacer-48;
14
+ display: grid;
15
+ background: white;
16
+ }
17
+
18
+ #TOC {
19
+ position: absolute;
20
+ top: 0;
21
+ z-index: 2;
22
+ left: 0;
23
+ right: 0;
24
+ }
25
+
26
+ #TOC > #TOC-list {
27
+ /* display: none; */
28
+ position: absolute;
29
+ left: 0;
30
+ right: 0;
31
+ z-index: 1;
32
+ background-color: #fff;
33
+ }
34
+
35
+ #TOC > .btn {
36
+ display: block;
37
+ }
38
+
39
+ #TOC + p {
40
+ display: none;
41
+ }
42
+
43
+ #TOC > #TOC-list {
44
+ list-style: none;
45
+ border-left: 5px solid #ff8500;
46
+ }
47
+
48
+ #TOC li {
49
+ display: block;
50
+ margin-block-start: 1em;
51
+ margin-block-end: 1em;
52
+ margin-inline-start: 0px;
53
+ margin-inline-end: 0px;
54
+
55
+ &:first-child {
56
+ margin-top: 0;
57
+ }
58
+ }
59
+
60
+ @include media-breakpoint-up(lg) {
61
+ #TOC {
62
+ position: relative;
63
+
64
+ > ul {
65
+ display: block;
66
+ }
67
+ > .btn {
68
+ display: none;
69
+ }
70
+ }
71
+
72
+ #TOC-list {
73
+ display: block !important;
74
+ }
75
+
76
+ .modal-body {
77
+ display: grid;
78
+ grid-template-columns: 10em 1fr;
79
+ gap: 3.2rem;
80
+ }
81
+ }
82
+ }
@@ -1,33 +1,133 @@
1
+ @use "sass:map";
2
+
1
3
  // Array Widget Flash Colors
4
+ // Global colors are wrong according to figma palette, so I redeclare them here....
2
5
  $widget-flash-colors: (
3
- "red": $red,
4
- "orange": $orange,
5
- "green": $green,
6
- "blue": $blue,
7
- "grey-dark": $gray-700,
6
+ "red": (
7
+ "background": #FFECEE,
8
+ "shadow": #FFADB9,
9
+ "badge": #FF3A55
10
+ ),
11
+ "orange": (
12
+ "background": #FFEFE3,
13
+ "shadow": #FFCBA0,
14
+ "badge": #FF8D2E
15
+ ),
16
+ "green": (
17
+ "background": #E6F9F8,
18
+ "shadow": #B6EDE5,
19
+ "badge": #46BFAF
20
+ ),
21
+ "blue": (
22
+ "background": #E5F5FF,
23
+ "shadow": #B9E3F8,
24
+ "badge": #2A9CC8
25
+ ),
26
+ "grey-dark": (
27
+ "background": $gray-300,
28
+ "shadow": $gray-400,
29
+ "badge": $gray-600
30
+ ),
8
31
  );
9
32
 
10
33
  .widget-flash {
11
- position: relative;
12
- padding: $widget-padding-x;
13
- overflow: hidden;
14
- color: $white;
15
34
  background: $secondary;
16
-
35
+
36
+ padding: 36px 24px 24px;
37
+ position: relative;
38
+ border-radius: 8px 8px 8px 6px;
39
+ margin: 32px 4px 36px 0;
40
+ left: 4px;
41
+ bottom: 4px;
42
+ &:last-child {
43
+ margin-bottom: 28px;
44
+ }
45
+
17
46
  @each $key, $value in $widget-flash-colors {
18
47
  &.#{$key} {
19
- --custom-message-color: #{$value};
20
- background-color: $value;
48
+ --custom-message-color: #{map.get($value, "background")};
49
+ background-color: map.get($value, "background");
50
+ box-shadow: map.get($value, "shadow") -4px 0px,
51
+ map.get($value, "shadow") 0px 4px,
52
+ map.get($value, "shadow") -2px 2px 0 2px;
53
+
54
+ &::before {
55
+ background-color: map.get($value, "badge");
56
+ border-color: map.get($value, "shadow");
57
+ box-shadow: 0 0 0 4px map.get($value, "background");
58
+ }
59
+
60
+ .btn-expand-inner {
61
+ background-color: map.get($value, "background");
62
+ }
63
+
64
+ .flash-content:not(.flash-content-is-expandable) .btn-expand-inner::before {
65
+ background: linear-gradient(to right,
66
+ rgba(map.get($value, "background"), 0),
67
+ rgba(map.get($value, "background"), 0.5) 30%,
68
+ rgba(map.get($value, "background"), 0.8) 50%,
69
+ rgba(map.get($value, "background"), 0.95) 75%,
70
+ map.get($value, "background") 100%);
71
+ }
21
72
  }
22
73
  }
23
74
 
75
+ &::before {
76
+ content: '';
77
+ position: absolute;
78
+ display: block;
79
+ top: 4px-52px+24px + 8px;
80
+ left: 4px+24px;
81
+ width: 36px;
82
+ height: 36px;
83
+ border-radius: 100%;
84
+ border-width: 4px;
85
+ border-style: solid;
86
+ box-sizing: content-box;
87
+ }
88
+
89
+ .flash-icon {
90
+ position: absolute;
91
+ display: block;
92
+ top: 4px-52px+24px + 8px + 10px;
93
+ left: 4px+24px + 10px;
94
+ width: 24px;
95
+ height: 24px;
96
+ color: $white;
97
+ }
98
+ &.red .flash-icon{
99
+ // 'alert-triangle' icon seems vertically misaligned.
100
+ transform: translateY(-1px);
101
+ }
102
+
24
103
  .btn {
25
104
  &-close {
26
105
  position: absolute;
27
- top: 10px;
28
- right: 10px;
29
- color: var(--ode-dark);
30
- text-shadow: none;
106
+ top: 0;
107
+ right: 0;
108
+ width: 20px + 16px;
109
+ height: 20px + 16px;
110
+ padding: 8px;
111
+ box-sizing: border-box;
112
+ border-radius: 8px;
113
+ color: $text-color;
114
+ background-color: initial;
115
+ background-image: initial;
116
+ opacity: initial;
117
+
118
+ &:hover {
119
+ background-color: $gray-300;
120
+ }
121
+
122
+ &:active {
123
+ background-color: $gray-400;
124
+ color: $black;
125
+ }
126
+
127
+ &:focus {
128
+ background-color: $gray-300;
129
+ border: solid 1px $gray-400;
130
+ }
31
131
  }
32
132
 
33
133
  &-expand {
@@ -36,17 +136,22 @@ $widget-flash-colors: (
36
136
  &-inner {
37
137
  position: absolute;
38
138
  z-index: 2;
39
- bottom: 0;
40
- left: 0;
139
+ bottom: 24px;
140
+ right: 18px;
41
141
  display: block;
42
- width: 100%;
43
- padding: 5px;
44
- font-size: 0.8em;
45
- color: $white;
142
+ padding-right: 16px;
46
143
  text-align: center;
47
- background: rgba(#000, 0.1);
144
+ font-weight: bold;
48
145
 
49
- @include background-color-to(rgba(#000, 0.2));
146
+ &::before {
147
+ content: '';
148
+ display: block;
149
+ position: absolute;
150
+ width: 64px;
151
+ height: 100%;
152
+ // background: linear-gradient(to right, rgba($flash-red, 0), rgba($flash-red, 0.5) 30%, rgba($flash-red, 0.8) 50%, rgba($flash-red, 0.95) 75%, $flash-red 100%);
153
+ left: -64px;
154
+ }
50
155
  }
51
156
  }
52
157
  }
@@ -54,31 +159,32 @@ $widget-flash-colors: (
54
159
  .flash-content {
55
160
  padding-right: 1rem;
56
161
 
57
- p {
58
- > br:first-child {
162
+ // Merge multiple <br> into one and delete the first empty line if present
163
+ p, p>div {
164
+ & > br:first-child, & > br:not(:not(br)+br) {
59
165
  display: none;
60
166
  }
61
167
  }
62
168
 
169
+ a {
170
+ color: inherit;
171
+ text-decoration: underline;
172
+ font-weight: bold;
173
+
174
+ &:hover {
175
+ color: $black;
176
+ }
177
+
178
+ &:active {
179
+ color: #550070;
180
+ }
181
+ }
182
+
63
183
  &.can-be-truncated {
64
184
  &:not(.flash-content-is-expandable) {
65
185
  p {
66
186
  @include has-text-truncated(4);
67
- }
68
-
69
- &::after {
70
- content: "";
71
- position: absolute;
72
- z-index: 1;
73
- bottom: 2em;
74
- right: 0;
75
- left: 0;
76
- height: 4em;
77
- background: linear-gradient(
78
- to bottom,
79
- rgba(255, 255, 255, 0),
80
- var(--custom-message-color)
81
- );
187
+ padding-bottom: 0;
82
188
  }
83
189
 
84
190
  @media not all and (min-resolution: 0.001dpcm) {
@@ -93,7 +199,9 @@ $widget-flash-colors: (
93
199
  }
94
200
 
95
201
  .flash-content-signature {
96
- padding-bottom: 1rem;
202
+ font-style: italic;
203
+ margin-top: 22px !important;
204
+ margin-right: 12em;
97
205
  }
98
206
  }
99
207