@pecb-ui/components 1.1.12 → 1.1.13
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 +321 -0
- package/fesm2022/pecb-ui-components-navigation.mjs +1 -1
- package/fesm2022/pecb-ui-components-navigation.mjs.map +1 -1
- package/fesm2022/pecb-ui-components.mjs +1735 -168
- package/fesm2022/pecb-ui-components.mjs.map +1 -1
- package/index.d.ts +980 -5
- package/lib/components/shadow/shadow.directive.scss +42 -0
- package/navigation/index.d.ts +1 -1
- package/package.json +6 -2
- package/styles/abstracts/_mixins.scss +331 -0
- package/styles/abstracts/_variables.scss +328 -0
- package/styles/base/_container.scss +26 -0
- package/styles/base/_reset.scss +72 -0
- package/styles/main.scss +12 -0
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
@use "../../../styles/abstracts/variables" as *;
|
|
2
|
+
|
|
3
|
+
// =============================================================================
|
|
4
|
+
// SHADOW SOFT CLASSES
|
|
5
|
+
// =============================================================================
|
|
6
|
+
|
|
7
|
+
@each $name, $value in $shadow-soft-map {
|
|
8
|
+
.pecb-shadow-soft--#{$name} {
|
|
9
|
+
box-shadow: $value;
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
// =============================================================================
|
|
14
|
+
// SHADOW HARD CLASSES
|
|
15
|
+
// =============================================================================
|
|
16
|
+
|
|
17
|
+
@each $name, $value in $shadow-hard-map {
|
|
18
|
+
.pecb-shadow-hard--#{$name} {
|
|
19
|
+
box-shadow: $value;
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
// =============================================================================
|
|
24
|
+
// BLUR CLASSES (element filter)
|
|
25
|
+
// =============================================================================
|
|
26
|
+
|
|
27
|
+
@each $name, $value in $blur-map {
|
|
28
|
+
.pecb-blur--#{$name} {
|
|
29
|
+
filter: blur($value);
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
// =============================================================================
|
|
34
|
+
// BACKDROP BLUR CLASSES (glass-morphism)
|
|
35
|
+
// =============================================================================
|
|
36
|
+
|
|
37
|
+
@each $name, $value in $blur-map {
|
|
38
|
+
.pecb-backdrop-blur--#{$name} {
|
|
39
|
+
backdrop-filter: blur($value);
|
|
40
|
+
-webkit-backdrop-filter: blur($value);
|
|
41
|
+
}
|
|
42
|
+
}
|
package/navigation/index.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { AdminHeaderAction, AdminHeaderActionType, AdminHeaderBadgeVariant, AdminHeaderComponent, AdminHeaderField, AdminHeaderFieldTemplateDirective, AdminHeaderFieldType, AdminHeaderMetadata, AdminHeaderMetadataType, AdminHeaderProfile, AffixComponent, AffixPosition, AnchorComponent, AnchorDirection, AnchorItem, AnchorLevel, BackToTopComponent, BreadcrumbSeparator, BreadcrumbsComponent, DEFAULT_LANGUAGES, HeaderActionButton, HeaderActionsComponent, HeaderComponent, HeaderDividerComponent, HeaderLanguageComponent, HeaderLanguageOption, HeaderSearchCategory, HeaderSearchComponent, HeaderUserComponent, LanguageDisplayMode, LanguageDropdownComponent, LanguageOption, StepItem, StepOrder, StepState, StepperComponent, StepperDirection, StepperSize, StepperTailStyle, StepperType, TabComponent, TabSize, TabStyle } from '@pecb-ui/components';
|
|
1
|
+
export { APP_SIDEBAR_MENU_ICONS, AdminHeaderAction, AdminHeaderActionType, AdminHeaderBadgeVariant, AdminHeaderComponent, AdminHeaderField, AdminHeaderFieldTemplateDirective, AdminHeaderFieldType, AdminHeaderMetadata, AdminHeaderMetadataType, AdminHeaderProfile, AffixComponent, AffixPosition, AnchorComponent, AnchorDirection, AnchorItem, AnchorLevel, AppHeaderAction, AppHeaderChip, AppHeaderChipTone, AppHeaderComponent, AppHeaderLabels, AppHeaderNotification, AppSidebarComponent, AppSidebarLabels, AppSidebarMenuItem, AppSidebarMenuOption, AppSidebarMenuOptionChange, AppSidebarNavGroup, AppSidebarNavItem, AppSidebarProduct, AppSidebarRouterLink, AppSidebarUser, BackToTopComponent, BreadcrumbSeparator, BreadcrumbsComponent, DEFAULT_APP_HEADER_LABELS, DEFAULT_APP_SIDEBAR_LABELS, DEFAULT_APP_SIDEBAR_LANGUAGES, DEFAULT_APP_SIDEBAR_MENU, DEFAULT_APP_SIDEBAR_ROLES, DEFAULT_LANGUAGES, HeaderActionButton, HeaderActionsComponent, HeaderComponent, HeaderDividerComponent, HeaderLanguageComponent, HeaderLanguageOption, HeaderSearchCategory, HeaderSearchComponent, HeaderUserComponent, LanguageDisplayMode, LanguageDropdownComponent, LanguageOption, StepItem, StepOrder, StepState, StepperComponent, StepperDirection, StepperSize, StepperTailStyle, StepperType, TabComponent, TabSize, TabStyle } from '@pecb-ui/components';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pecb-ui/components",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.13",
|
|
4
4
|
"description": "Professional Angular UI Components Library with TypeScript and SCSS by PECB",
|
|
5
5
|
"author": "PECB",
|
|
6
6
|
"license": "MIT",
|
|
@@ -32,11 +32,15 @@
|
|
|
32
32
|
"@angular/cdk": "^20.0.0",
|
|
33
33
|
"@angular/animations": "^20.0.0",
|
|
34
34
|
"@angular/platform-browser": "^20.0.0",
|
|
35
|
-
"rxjs": "^7.8.0"
|
|
35
|
+
"rxjs": "^7.8.0",
|
|
36
|
+
"@angular/router": "^20.0.0"
|
|
36
37
|
},
|
|
37
38
|
"peerDependenciesMeta": {
|
|
38
39
|
"@angular/animations": {
|
|
39
40
|
"optional": true
|
|
41
|
+
},
|
|
42
|
+
"@angular/router": {
|
|
43
|
+
"optional": true
|
|
40
44
|
}
|
|
41
45
|
},
|
|
42
46
|
"dependencies": {
|
|
@@ -0,0 +1,331 @@
|
|
|
1
|
+
@use "sass:color";
|
|
2
|
+
@use "sass:map";
|
|
3
|
+
@use "variables" as *;
|
|
4
|
+
|
|
5
|
+
// Responsive breakpoint mixin
|
|
6
|
+
@mixin respond-to($breakpoint) {
|
|
7
|
+
@if $breakpoint == "xs" {
|
|
8
|
+
@media (min-width: $breakpoint-xs) {
|
|
9
|
+
@content;
|
|
10
|
+
}
|
|
11
|
+
} @else if $breakpoint == "sm" {
|
|
12
|
+
@media (min-width: $breakpoint-sm) {
|
|
13
|
+
@content;
|
|
14
|
+
}
|
|
15
|
+
} @else if $breakpoint == "md" {
|
|
16
|
+
@media (min-width: $breakpoint-md) {
|
|
17
|
+
@content;
|
|
18
|
+
}
|
|
19
|
+
} @else if $breakpoint == "lg" {
|
|
20
|
+
@media (min-width: $breakpoint-lg) {
|
|
21
|
+
@content;
|
|
22
|
+
}
|
|
23
|
+
} @else if $breakpoint == "xl" {
|
|
24
|
+
@media (min-width: $breakpoint-xl) {
|
|
25
|
+
@content;
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
// Flexbox utilities
|
|
31
|
+
@mixin flex-center {
|
|
32
|
+
display: flex;
|
|
33
|
+
align-items: center;
|
|
34
|
+
justify-content: center;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
@mixin flex-between {
|
|
38
|
+
display: flex;
|
|
39
|
+
align-items: center;
|
|
40
|
+
justify-content: space-between;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
@mixin flex-column {
|
|
44
|
+
display: flex;
|
|
45
|
+
flex-direction: column;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
// Truncate text
|
|
49
|
+
@mixin text-truncate {
|
|
50
|
+
overflow: hidden;
|
|
51
|
+
text-overflow: ellipsis;
|
|
52
|
+
white-space: nowrap;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
// Multi-line truncate
|
|
56
|
+
@mixin line-clamp($lines: 2) {
|
|
57
|
+
display: -webkit-box;
|
|
58
|
+
-webkit-line-clamp: $lines;
|
|
59
|
+
-webkit-box-orient: vertical;
|
|
60
|
+
overflow: hidden;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
// Custom scrollbar
|
|
64
|
+
@mixin custom-scrollbar($thumb-color: $neutral-4, $track-color: $neutral-5) {
|
|
65
|
+
&::-webkit-scrollbar {
|
|
66
|
+
width: 8px;
|
|
67
|
+
height: 8px;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
&::-webkit-scrollbar-track {
|
|
71
|
+
background: $track-color;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
&::-webkit-scrollbar-thumb {
|
|
75
|
+
background: $thumb-color;
|
|
76
|
+
border-radius: $border-radius-md;
|
|
77
|
+
|
|
78
|
+
&:hover {
|
|
79
|
+
background: color.adjust($thumb-color, $lightness: -10%);
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
// Button reset
|
|
85
|
+
@mixin button-reset {
|
|
86
|
+
padding: 0;
|
|
87
|
+
border: none;
|
|
88
|
+
background: none;
|
|
89
|
+
cursor: pointer;
|
|
90
|
+
font: inherit;
|
|
91
|
+
color: inherit;
|
|
92
|
+
|
|
93
|
+
&:focus {
|
|
94
|
+
outline: none;
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
// Aspect ratio
|
|
99
|
+
@mixin aspect-ratio($width: 16, $height: 9) {
|
|
100
|
+
position: relative;
|
|
101
|
+
|
|
102
|
+
&::before {
|
|
103
|
+
content: "";
|
|
104
|
+
display: block;
|
|
105
|
+
padding-top: calc(($height / $width) * 100%);
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
> * {
|
|
109
|
+
position: absolute;
|
|
110
|
+
top: 0;
|
|
111
|
+
left: 0;
|
|
112
|
+
width: 100%;
|
|
113
|
+
height: 100%;
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
// Focus visible styles
|
|
118
|
+
@mixin focus-visible($color: $primary-color) {
|
|
119
|
+
&:focus-visible {
|
|
120
|
+
outline: 2px solid $color;
|
|
121
|
+
outline-offset: 2px;
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
// Elevation/Shadow
|
|
126
|
+
@mixin elevation($level: 1) {
|
|
127
|
+
@if $level == 1 {
|
|
128
|
+
box-shadow: $shadow-sm;
|
|
129
|
+
} @else if $level == 2 {
|
|
130
|
+
box-shadow: $shadow-md;
|
|
131
|
+
} @else if $level == 3 {
|
|
132
|
+
box-shadow: $shadow-lg;
|
|
133
|
+
} @else if $level == 4 {
|
|
134
|
+
box-shadow: $shadow-xl;
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
// Transition
|
|
139
|
+
@mixin transition($properties...) {
|
|
140
|
+
transition-property: $properties;
|
|
141
|
+
transition-duration: $transition-base;
|
|
142
|
+
transition-timing-function: ease-in-out;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
// Shadow Soft
|
|
146
|
+
@mixin shadow-soft($size: "medium") {
|
|
147
|
+
box-shadow: map.get($shadow-soft-map, $size);
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
// Shadow Hard
|
|
151
|
+
@mixin shadow-hard($size: "medium") {
|
|
152
|
+
box-shadow: map.get($shadow-hard-map, $size);
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
// Blur (backdrop or element)
|
|
156
|
+
@mixin blur($size: "medium") {
|
|
157
|
+
$value: map.get($blur-map, $size);
|
|
158
|
+
filter: blur($value);
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
// Backdrop blur (glass-morphism)
|
|
162
|
+
@mixin backdrop-blur($size: "medium") {
|
|
163
|
+
$value: map.get($blur-map, $size);
|
|
164
|
+
backdrop-filter: blur($value);
|
|
165
|
+
-webkit-backdrop-filter: blur($value);
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
// ============================================
|
|
169
|
+
// TYPOGRAPHY MIXINS
|
|
170
|
+
// ============================================
|
|
171
|
+
|
|
172
|
+
// Base typography
|
|
173
|
+
@mixin font-base {
|
|
174
|
+
font-family: $font-family-base;
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
// Headings
|
|
178
|
+
@mixin h1($weight: $font-weight-regular) {
|
|
179
|
+
@include font-base;
|
|
180
|
+
font-size: $font-size-32;
|
|
181
|
+
font-weight: $weight;
|
|
182
|
+
line-height: $line-height-heading;
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
@mixin h1-bold {
|
|
186
|
+
@include h1($font-weight-bold);
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
@mixin h1-medium {
|
|
190
|
+
@include h1($font-weight-medium);
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
@mixin h2($weight: $font-weight-regular) {
|
|
194
|
+
@include font-base;
|
|
195
|
+
font-size: $font-size-24;
|
|
196
|
+
font-weight: $weight;
|
|
197
|
+
line-height: $line-height-heading;
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
@mixin h2-bold {
|
|
201
|
+
@include h2($font-weight-bold);
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
@mixin h2-medium {
|
|
205
|
+
@include h2($font-weight-medium);
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
@mixin h3($weight: $font-weight-regular) {
|
|
209
|
+
@include font-base;
|
|
210
|
+
font-size: $font-size-20;
|
|
211
|
+
font-weight: $weight;
|
|
212
|
+
line-height: $line-height-heading;
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
@mixin h3-bold {
|
|
216
|
+
@include h3($font-weight-bold);
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
@mixin h3-medium {
|
|
220
|
+
@include h3($font-weight-medium);
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
// Body text
|
|
224
|
+
@mixin body-12($weight: $font-weight-regular) {
|
|
225
|
+
@include font-base;
|
|
226
|
+
font-size: $font-size-12;
|
|
227
|
+
font-weight: $weight;
|
|
228
|
+
line-height: $line-height-base;
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
@mixin body-13($weight: $font-weight-regular) {
|
|
232
|
+
@include font-base;
|
|
233
|
+
font-size: $font-size-13;
|
|
234
|
+
font-weight: $weight;
|
|
235
|
+
line-height: $line-height-base;
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
@mixin body-14($weight: $font-weight-regular) {
|
|
239
|
+
@include font-base;
|
|
240
|
+
font-size: $font-size-14;
|
|
241
|
+
font-weight: $weight;
|
|
242
|
+
line-height: $line-height-base;
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
@mixin body-16($weight: $font-weight-regular) {
|
|
246
|
+
@include font-base;
|
|
247
|
+
font-size: $font-size-16;
|
|
248
|
+
font-weight: $weight;
|
|
249
|
+
line-height: $line-height-base;
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
@mixin body-18($weight: $font-weight-regular) {
|
|
253
|
+
@include font-base;
|
|
254
|
+
font-size: $font-size-18;
|
|
255
|
+
font-weight: $weight;
|
|
256
|
+
line-height: $line-height-base;
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
// Caption
|
|
260
|
+
@mixin caption($weight: $font-weight-regular) {
|
|
261
|
+
@include font-base;
|
|
262
|
+
font-size: $font-size-caption;
|
|
263
|
+
font-weight: $weight;
|
|
264
|
+
line-height: $line-height-base;
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
@mixin caption-bold {
|
|
268
|
+
@include caption($font-weight-bold);
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
// Hero text
|
|
272
|
+
@mixin hero-1($weight: $font-weight-regular) {
|
|
273
|
+
@include font-base;
|
|
274
|
+
font-size: $font-size-48;
|
|
275
|
+
font-weight: $weight;
|
|
276
|
+
line-height: $line-height-tight;
|
|
277
|
+
}
|
|
278
|
+
|
|
279
|
+
@mixin hero-1-medium {
|
|
280
|
+
@include hero-1($font-weight-medium);
|
|
281
|
+
}
|
|
282
|
+
|
|
283
|
+
@mixin hero-1-bold {
|
|
284
|
+
@include hero-1($font-weight-bold);
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
@mixin hero-2($weight: $font-weight-regular) {
|
|
288
|
+
@include font-base;
|
|
289
|
+
font-size: $font-size-40;
|
|
290
|
+
font-weight: $weight;
|
|
291
|
+
line-height: $line-height-tight;
|
|
292
|
+
}
|
|
293
|
+
|
|
294
|
+
@mixin hero-2-medium {
|
|
295
|
+
@include hero-2($font-weight-medium);
|
|
296
|
+
}
|
|
297
|
+
|
|
298
|
+
@mixin hero-2-bold {
|
|
299
|
+
@include hero-2($font-weight-bold);
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
@mixin hero-3($weight: $font-weight-regular) {
|
|
303
|
+
@include font-base;
|
|
304
|
+
font-size: $font-size-32;
|
|
305
|
+
font-weight: $weight;
|
|
306
|
+
line-height: $line-height-tight;
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
@mixin hero-3-medium {
|
|
310
|
+
@include hero-3($font-weight-medium);
|
|
311
|
+
}
|
|
312
|
+
|
|
313
|
+
@mixin hero-3-bold {
|
|
314
|
+
@include hero-3($font-weight-bold);
|
|
315
|
+
}
|
|
316
|
+
|
|
317
|
+
// Content container — the centred page measure from the PECB designs
|
|
318
|
+
// (`.wrap { max-width: 1180px; margin: 0 auto; padding: 14px }`, gutter
|
|
319
|
+
// widening to 16px below 880px). Emitted as `.pecb-container` in base/container;
|
|
320
|
+
// include the mixin directly when a component needs the measure in its own CSS.
|
|
321
|
+
@mixin content-container($max-width: var(--pecb-container-max-width, 1180px)) {
|
|
322
|
+
box-sizing: border-box;
|
|
323
|
+
width: 100%;
|
|
324
|
+
max-width: $max-width;
|
|
325
|
+
margin-inline: auto;
|
|
326
|
+
padding: 14px;
|
|
327
|
+
|
|
328
|
+
@media (max-width: 880px) {
|
|
329
|
+
padding: 16px;
|
|
330
|
+
}
|
|
331
|
+
}
|