@tedi-design-system/core 2.0.0
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 +14 -0
- package/_base.scss +93 -0
- package/_fonts.scss +253 -0
- package/_helpers.scss +43 -0
- package/_icons.scss +51 -0
- package/_mixins.scss +108 -0
- package/_print.scss +35 -0
- package/_typography.scss +220 -0
- package/bootstrap-utility/_breakpoints.scss +136 -0
- package/bootstrap-utility/_grid.scss +167 -0
- package/bootstrap-utility/_mixin-utilities.scss +95 -0
- package/bootstrap-utility/_utilities-api.scss +23 -0
- package/bootstrap-utility/_utilities.scss +104 -0
- package/fonts/README.md +34 -0
- package/fonts/material-symbols-outlined.woff2 +0 -0
- package/fonts/material-symbols-rounded.woff2 +0 -0
- package/fonts/material-symbols-sharp.woff2 +0 -0
- package/fonts/roboto-v30-cyrillic-300-italic.woff2 +0 -0
- package/fonts/roboto-v30-cyrillic-300.woff2 +0 -0
- package/fonts/roboto-v30-cyrillic-400-italic.woff2 +0 -0
- package/fonts/roboto-v30-cyrillic-400.woff2 +0 -0
- package/fonts/roboto-v30-cyrillic-700-italic.woff2 +0 -0
- package/fonts/roboto-v30-cyrillic-700.woff2 +0 -0
- package/fonts/roboto-v30-cyrillic-ext-300-italic.woff2 +0 -0
- package/fonts/roboto-v30-cyrillic-ext-300.woff2 +0 -0
- package/fonts/roboto-v30-cyrillic-ext-400-italic.woff2 +0 -0
- package/fonts/roboto-v30-cyrillic-ext-400.woff2 +0 -0
- package/fonts/roboto-v30-cyrillic-ext-700-italic.woff2 +0 -0
- package/fonts/roboto-v30-cyrillic-ext-700.woff2 +0 -0
- package/fonts/roboto-v30-latin-300-italic.woff2 +0 -0
- package/fonts/roboto-v30-latin-300.woff2 +0 -0
- package/fonts/roboto-v30-latin-400-italic.woff2 +0 -0
- package/fonts/roboto-v30-latin-400.woff2 +0 -0
- package/fonts/roboto-v30-latin-700-italic.woff2 +0 -0
- package/fonts/roboto-v30-latin-700.woff2 +0 -0
- package/fonts/roboto-v30-latin-ext-300-italic.woff2 +0 -0
- package/fonts/roboto-v30-latin-ext-300.woff2 +0 -0
- package/fonts/roboto-v30-latin-ext-400-italic.woff2 +0 -0
- package/fonts/roboto-v30-latin-ext-400.woff2 +0 -0
- package/fonts/roboto-v30-latin-ext-700-italic.woff2 +0 -0
- package/fonts/roboto-v30-latin-ext-700.woff2 +0 -0
- package/index.css +1 -0
- package/index.scss +17 -0
- package/package.json +63 -0
- package/tedi-storybook-styles.scss +172 -0
- package/variables/_base-variables.scss +168 -0
- package/variables/_bootstrap-variables.scss +30 -0
- package/variables/_color-variables.scss +1113 -0
- package/variables/_dimensional-variables.scss +1236 -0
- package/variables/_font-variables.scss +77 -0
- package/variables/_utility-variables.scss +11 -0
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
@use 'sass:map';
|
|
2
|
+
@use '../variables/bootstrap-variables' as vars;
|
|
3
|
+
|
|
4
|
+
// Utilities
|
|
5
|
+
|
|
6
|
+
$utilities: () !default;
|
|
7
|
+
// stylelint-disable-next-line scss/dollar-variable-default
|
|
8
|
+
$utilities: map.merge(
|
|
9
|
+
(
|
|
10
|
+
'flex': (
|
|
11
|
+
responsive: true,
|
|
12
|
+
property: flex,
|
|
13
|
+
values: (
|
|
14
|
+
fill: 1 1 auto,
|
|
15
|
+
),
|
|
16
|
+
),
|
|
17
|
+
'flex-direction': (
|
|
18
|
+
responsive: true,
|
|
19
|
+
property: flex-direction,
|
|
20
|
+
class: flex,
|
|
21
|
+
values: row column row-reverse column-reverse,
|
|
22
|
+
),
|
|
23
|
+
'flex-grow': (
|
|
24
|
+
responsive: true,
|
|
25
|
+
property: flex-grow,
|
|
26
|
+
class: flex,
|
|
27
|
+
values: (
|
|
28
|
+
grow-0: 0,
|
|
29
|
+
grow-1: 1,
|
|
30
|
+
),
|
|
31
|
+
),
|
|
32
|
+
'flex-shrink': (
|
|
33
|
+
responsive: true,
|
|
34
|
+
property: flex-shrink,
|
|
35
|
+
class: flex,
|
|
36
|
+
values: (
|
|
37
|
+
shrink-0: 0,
|
|
38
|
+
shrink-1: 1,
|
|
39
|
+
),
|
|
40
|
+
),
|
|
41
|
+
'flex-wrap': (
|
|
42
|
+
responsive: true,
|
|
43
|
+
property: flex-wrap,
|
|
44
|
+
class: flex,
|
|
45
|
+
values: wrap nowrap wrap-reverse,
|
|
46
|
+
),
|
|
47
|
+
'justify-content': (
|
|
48
|
+
responsive: true,
|
|
49
|
+
property: justify-content,
|
|
50
|
+
values: (
|
|
51
|
+
start: flex-start,
|
|
52
|
+
end: flex-end,
|
|
53
|
+
center: center,
|
|
54
|
+
between: space-between,
|
|
55
|
+
around: space-around,
|
|
56
|
+
evenly: space-evenly,
|
|
57
|
+
),
|
|
58
|
+
),
|
|
59
|
+
'align-items': (
|
|
60
|
+
responsive: true,
|
|
61
|
+
property: align-items,
|
|
62
|
+
values: (
|
|
63
|
+
start: flex-start,
|
|
64
|
+
end: flex-end,
|
|
65
|
+
center: center,
|
|
66
|
+
baseline: baseline,
|
|
67
|
+
stretch: stretch,
|
|
68
|
+
),
|
|
69
|
+
),
|
|
70
|
+
'align-self': (
|
|
71
|
+
responsive: true,
|
|
72
|
+
property: align-self,
|
|
73
|
+
values: (
|
|
74
|
+
auto: auto,
|
|
75
|
+
start: flex-start,
|
|
76
|
+
end: flex-end,
|
|
77
|
+
center: center,
|
|
78
|
+
baseline: baseline,
|
|
79
|
+
stretch: stretch,
|
|
80
|
+
),
|
|
81
|
+
),
|
|
82
|
+
'order': (
|
|
83
|
+
responsive: true,
|
|
84
|
+
property: order,
|
|
85
|
+
values: (
|
|
86
|
+
first: -1,
|
|
87
|
+
0: 0,
|
|
88
|
+
1: 1,
|
|
89
|
+
2: 2,
|
|
90
|
+
3: 3,
|
|
91
|
+
4: 4,
|
|
92
|
+
5: 5,
|
|
93
|
+
last: 6,
|
|
94
|
+
),
|
|
95
|
+
),
|
|
96
|
+
'gap': (
|
|
97
|
+
responsive: true,
|
|
98
|
+
property: gap,
|
|
99
|
+
class: gap,
|
|
100
|
+
values: vars.$spacers,
|
|
101
|
+
),
|
|
102
|
+
),
|
|
103
|
+
$utilities
|
|
104
|
+
);
|
package/fonts/README.md
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
Vite build pipeline doesn't allow separate [asset files](https://vitejs.dev/config/build-options.html#build-assetsinlinelimit) during library build.
|
|
2
|
+
Currently, they get bundled in code (JS, CSS) and when we have lots of fonts, then the outputted CSS is huge.
|
|
3
|
+
|
|
4
|
+
The only way to not inline font files is to put them in public folder and to make sure they can't be found during build time.
|
|
5
|
+
For storybook the assets should be absolute urls. For component library they should be relative.
|
|
6
|
+
|
|
7
|
+
Affected files are \_icons.scss, \_fonts.scss. Fonts folder in src/public and build script in package.json
|
|
8
|
+
|
|
9
|
+
### To update material-symbols font files:
|
|
10
|
+
|
|
11
|
+
- download the font files from the following urls
|
|
12
|
+
- https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@24,400,0.1,0
|
|
13
|
+
- https://fonts.googleapis.com/css2?family=Material+Symbols+Rounded:opsz,wght,FILL,GRAD@24,400,0.1,0
|
|
14
|
+
- https://fonts.googleapis.com/css2?family=Material+Symbols+Sharp:opsz,wght,FILL,GRAD@24,400,0.1,0
|
|
15
|
+
- 24 stands for the font size in px
|
|
16
|
+
- 400 stands for the font weight (only 'normal' is supported)
|
|
17
|
+
- 0.1 means that both regular and filled icons are included
|
|
18
|
+
- 0 is for grade (not used)
|
|
19
|
+
- https://fonts.google.com/icons
|
|
20
|
+
- keep in mind that while it is possible to extend these parameters, each added value increases the size of the font file -> slower loading times
|
|
21
|
+
- rename the downloaded files and copy them to src/public/fonts
|
|
22
|
+
|
|
23
|
+
### To update roboto font files:
|
|
24
|
+
|
|
25
|
+
In most cases this is never needed. Unless we want to add support for new weights or styles.
|
|
26
|
+
|
|
27
|
+
- download the font files from the following url
|
|
28
|
+
- https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,300;0,400;0,700;1,300;1,400;1,700&display=swap
|
|
29
|
+
- rename each of the files to match the weight and style of the font. Example `roboto-v30-latin-ext-300-italic.woff2`
|
|
30
|
+
- add or update the @font-face in the `/src/styles/_fonts.scss`
|
|
31
|
+
- make sure the font is rendered correctly in the https://disainipesa-react.tehik.ee/?path=/story/components-typography-text--font-variants story
|
|
32
|
+
|
|
33
|
+
https://github.com/vitejs/vite/issues/4454
|
|
34
|
+
https://github.com/vitejs/vite/issues/3295
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|