@oardi/css-utils 0.22.0 → 0.23.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@oardi/css-utils",
3
- "version": "0.22.0",
3
+ "version": "0.23.0",
4
4
  "author": "Ardian Shala",
5
5
  "homepage": "https://css-utils.oardi.com",
6
6
  "description": "Powerful set of semantic css classes with support for breakpoints, directions and spacings",
package/readme.md CHANGED
@@ -4,7 +4,8 @@ Powerful set of CSS Utility classes for Colors, Typography, Spacings, Flex and C
4
4
 
5
5
  ## Showcase
6
6
 
7
- Browse the Showcase [here](https://css-utils.oardi.com/)
7
+ - Browse the Showcase [here](https://css-utils.oardi.com/)
8
+ - Stackblitz Demo [here](https://stackblitz.com/edit/oardi-css-utils/)
8
9
 
9
10
  ## Setup
10
11
 
@@ -32,7 +33,7 @@ This will import the theme with all utility classes and their responsive classes
32
33
  This will render a centered text:
33
34
 
34
35
  <div class="text-center">
35
- some text
36
+ some text centered
36
37
  </div>
37
38
 
38
39
  ### Use predefined component classes
@@ -1,5 +1,6 @@
1
1
  .drawer {
2
2
  --drawer-bg-color: #ffffff;
3
+ --drawer-border-right-color: var(--gray-90);
3
4
 
4
5
  display: flex;
5
6
  flex-direction: column;
@@ -9,9 +10,9 @@
9
10
  height: 100dvh;
10
11
  width: min(20rem, 100%);
11
12
  z-index: 1045;
12
- border-right: 2px solid var(--gray-90);
13
+ border-right: 2px solid var(--drawer-border-right-color);
13
14
  justify-content: start;
14
- background-color: var(--white);
15
+ background-color: var(--drawer-bg-color);
15
16
  transition: left 250ms ease-out;
16
17
 
17
18
  &.open ~ .overlay {
@@ -0,0 +1,43 @@
1
+ .table {
2
+ --table-color-type: initial;
3
+ --table-bg-type: initial;
4
+ --table-color-state: initial;
5
+ --table-bg-state: initial;
6
+ --table-color: var(--font-color);
7
+ --table-bg: var(--body-bg-color);
8
+ --table-border-color: var(--gray-80);
9
+ --table-accent-bg: transparent;
10
+ --table-striped-color: var(--font-color);
11
+ --table-striped-bg: rgba(var(--font-color-rgb), 0.05); // TODO
12
+ --table-active-color: var(--font-color);
13
+ --table-active-bg: rgba(var(--font-color-rgb), 0.1); // TODO
14
+ --table-hover-color: var(--font-color);
15
+ --table-hover-bg: rgba(var(--font-color-rgb), 0.075); // TODO
16
+ --table-border-width: 1px;
17
+
18
+ width: 100%;
19
+ margin-bottom: 1rem;
20
+ vertical-align: top;
21
+ border-color: var(--table-border-color);
22
+
23
+ & > thead {
24
+ vertical-align: bottom;
25
+ }
26
+
27
+ & > :not(caption) > * > * {
28
+ padding: 0.5rem 0.5rem;
29
+ color: var(--table-color-state, var(--table-color-type, var(--table-color)));
30
+ background-color: var(--table-bg);
31
+ border-bottom-width: var(--table-border-width);
32
+ box-shadow: inset 0 0 0 9999px var(--table-bg-state, var(--table-bg-type, var(--table-accent-bg)));
33
+ }
34
+
35
+ & > tbody {
36
+ vertical-align: inherit;
37
+ }
38
+
39
+ .table-striped > tbody > tr:nth-of-type(odd) > * {
40
+ --table-color-type: var(--table-striped-color);
41
+ --table-bg-type: var(--table-striped-bg);
42
+ }
43
+ }
@@ -2,6 +2,7 @@
2
2
  --tab-highlight: var(--highlight);
3
3
  --tab-bg-color: var(--white);
4
4
  --tab-content-bg-color: var(--white);
5
+ --tab-border-color: var(--gray-80);
5
6
 
6
7
  display: flex;
7
8
  cursor: pointer;
@@ -15,7 +16,7 @@
15
16
  text-align: center;
16
17
 
17
18
  padding: 16px 20px;
18
- border-bottom: 3px solid var(--gray-80);
19
+ border-bottom: 3px solid var(--tab-border-color);
19
20
  flex: 1 0 auto;
20
21
 
21
22
  transition: all 0.3s ease;
@@ -10,4 +10,5 @@
10
10
  @use './components/navbar.scss';
11
11
  @use './components/overlay.scss';
12
12
  @use './components/tabs.scss';
13
+ @use './components/table.scss';
13
14
  @use './components/toast.scss';
package/scss/reboot.scss CHANGED
@@ -50,6 +50,23 @@ sup {
50
50
 
51
51
  table {
52
52
  border-color: currentcolor;
53
+ caption-side: bottom;
54
+ border-collapse: collapse;
55
+
56
+ th {
57
+ text-align: -webkit-match-parent;
58
+ }
59
+ }
60
+
61
+ tbody,
62
+ td,
63
+ tfoot,
64
+ th,
65
+ thead,
66
+ tr {
67
+ border-color: inherit;
68
+ border-style: solid;
69
+ border-width: 0;
53
70
  }
54
71
 
55
72
  button,
@@ -84,6 +84,12 @@
84
84
  background-color: var(--white);
85
85
  }
86
86
 
87
+ /**
88
+ bg-dark (bottom -> page background),
89
+ bg (middle),
90
+ bg-light(top)?
91
+ */
92
+
87
93
  .img-responsive {
88
94
  width: 100%;
89
95
  }