@nuvoui/core 1.1.3 → 1.1.5

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,7 +1,7 @@
1
1
  {
2
2
  "name": "@nuvoui/core",
3
- "version": "1.1.3",
4
- "description": "NuvoUI Core SCSS Library",
3
+ "version": "1.1.5",
4
+ "description": "NuvoUI is a human-friendly SCSS framework designed for simplicity, and modern responsive designs.",
5
5
  "main": "dist/nuvoui.css",
6
6
  "module": "src/styles/index.scss",
7
7
  "files": [
@@ -25,12 +25,18 @@
25
25
  "keywords": [
26
26
  "scss",
27
27
  "css",
28
+ "framework",
28
29
  "nuvoui",
29
30
  "ui-library",
30
31
  "design-system",
31
- "frontend",
32
32
  "responsive",
33
- "modern"
33
+ "animations",
34
+ "frontend",
35
+ "modern-ui",
36
+ "web-development",
37
+ "responsive-design",
38
+ "developer-friendly",
39
+ "mixins"
34
40
  ],
35
41
  "author": {
36
42
  "name": "AALA IT Solutions",
@@ -40,6 +46,7 @@
40
46
  "bugs": {
41
47
  "url": "https://github.com/NuvoUI/core/issues"
42
48
  },
49
+ "homepage": "https://nuvoui.io/",
43
50
  "publishConfig": {
44
51
  "access": "public"
45
52
  },
@@ -2,6 +2,7 @@
2
2
 
3
3
  /* Import variables */
4
4
  @use '../utilities/variables' as *;
5
+ @use '../utilities/media-queries' as media;
5
6
 
6
7
  :root {
7
8
  --font-family-base: system-ui, -apple-system, "BlinkMacSystemFont", 'Segoe UI', "Roboto", "Oxygen", "Ubuntu", "Cantarell", sans-serif;
@@ -18,6 +19,7 @@ body {
18
19
  font-weight: 400;
19
20
  line-height: 1.5;
20
21
  color: var(--text-primary);
22
+ transition: background-color 0.2s ease-in-out, color 0.2s ease-in-out;
21
23
  }
22
24
 
23
25
  // Headings
@@ -62,6 +64,102 @@ small {
62
64
  font-size: map.get($font-sizes, 'sm');
63
65
  }
64
66
 
67
+ // Buttons
68
+ button {
69
+ padding: 0.5rem 1rem;
70
+ border: 0;
71
+ border-radius: 0.25rem;
72
+ background-color: var(--button-bg-color, #007bff); // Default button color
73
+ color: var(--button-text-color, #ffffff);
74
+ font-family: var(--font-family-base);
75
+ cursor: pointer;
76
+ transition: background-color 0.2s ease-in-out, color 0.2s ease-in-out;
77
+
78
+ &:hover {
79
+ background-color: var(--button-bg-color-hover, #0056b3); // Hover button color
80
+ }
81
+
82
+ &:focus {
83
+ outline: none;
84
+ }
85
+
86
+ &:disabled {
87
+ background-color: #e0e0e0; // Disabled button color
88
+ color: #a0a0a0; // Disabled text color
89
+ cursor: not-allowed;
90
+ }
91
+ }
92
+
93
+ // Inputs
94
+ input[type="text"],
95
+ input[type="email"],
96
+ input[type="password"],
97
+ input[type="number"],
98
+ input[type="search"],
99
+ textarea {
100
+ padding: 0.5rem;
101
+ border: 1px solid var(--border);
102
+ border-radius: 0.25rem;
103
+ width: 100%; // Full width
104
+ font-family: var(--font-family-base);
105
+ transition: border 0.2s ease-in-out;
106
+ &:focus {
107
+ border-color: var(--link-color);
108
+ outline: none;
109
+ }
110
+ }
111
+
112
+ // Checkboxes and Radio Buttons
113
+ input[type="checkbox"],
114
+ input[type="radio"] {
115
+ margin-right: 0.5rem; // Space between input and label
116
+ }
117
+
118
+ // Selects
119
+ select {
120
+ padding: 0.5rem;
121
+ border: 1px solid var(--border);
122
+ border-radius: 0.25rem;
123
+ width: 100%; // Full width
124
+ font-family: var(--font-family-base);
125
+ transition: border 0.2s ease-in-out;
126
+ &:focus {
127
+ border-color: var(--link-color);
128
+ outline: none;
129
+ }
130
+ }
131
+
132
+ // Blockquotes
133
+ blockquote {
134
+ margin: 1rem 0;
135
+ padding: 0.5rem 1rem;
136
+ border-left: 4px solid var(--border);
137
+ font-style: italic;
138
+ }
139
+
140
+ // Horizontal Rule
141
+ hr {
142
+ border: none;
143
+ border-top: 1px solid var(--border);
144
+ margin: 1rem 0;
145
+ }
146
+
147
+ // Images
148
+ img {
149
+ max-width: 100%; // Responsive images
150
+ height: auto;
151
+ }
152
+
153
+ // Figures and Captions
154
+ figure {
155
+ margin: 1rem 0;
156
+ }
157
+
158
+ figcaption {
159
+ font-size: 0.875rem; // Smaller font for captions
160
+ color: var(--text-secondary, #666); // Optional secondary text color
161
+ }
162
+
65
163
  // Links
66
164
  a {
67
165
  color: var(--link-color);
@@ -84,10 +182,19 @@ a {
84
182
  border: 0 !important;
85
183
  }
86
184
 
87
- .focus\:outline-none:focus {
88
- outline: none;
89
- }
90
185
 
91
- .focus\:ring:focus {
92
- box-shadow: 0 0 0 3px rgb(66 153 225 / 50%);
93
- }
186
+
187
+ code {
188
+ font-family: 'Courier New', Courier, monospace;
189
+ background-color: #f8f8f8;
190
+ color: #d63384;
191
+ padding: 2px 6px;
192
+ border-radius: 3px;
193
+ box-shadow: 0 2px 4px rgb(0 0 0 / 10%);
194
+ white-space: nowrap;
195
+
196
+ @include media.dark-mode {
197
+ background-color: #333;
198
+ color: #f8f8f2;
199
+ }
200
+ }
@@ -7,7 +7,7 @@
7
7
  padding: 0;
8
8
  }
9
9
 
10
- // Remove default margin
10
+ // Remove default margin and padding
11
11
  body,
12
12
  h1,
13
13
  h2,
@@ -21,6 +21,7 @@ blockquote,
21
21
  dl,
22
22
  dd {
23
23
  margin: 0;
24
+ padding: 0;
24
25
  }
25
26
 
26
27
  // Set core body defaults
@@ -51,11 +52,6 @@ textarea,
51
52
  select {
52
53
  font: inherit;
53
54
  transition: all 0.2s ease-in-out;
54
-
55
- &:focus {
56
- box-shadow: inset 0 0 7px 0 #60b0cd; /* Change this to your preferred color and width */
57
- outline: 2px solid #40c1bf; /* Change this to your preferred color and width */
58
- }
59
55
  }
60
56
 
61
57
  // Remove all animations and transitions for people that prefer not to see them
@@ -24,9 +24,7 @@
24
24
  @forward 'layouts/flex';
25
25
  @forward 'layouts/grid';
26
26
 
27
- // Themes
28
- @forward 'themes/light';
29
- @forward 'themes/dark';
27
+ // Theme
30
28
  @forward 'themes/theme';
31
29
 
32
30
  @forward './mixins-map';
@@ -1,7 +1,7 @@
1
1
  @use 'sass:map';
2
2
  @use '../utilities/variables' as *;
3
3
 
4
- // Container mixins
4
+ // Base container styles
5
5
  @mixin container-base {
6
6
  width: 100%;
7
7
  margin-left: auto;
@@ -10,39 +10,30 @@
10
10
  padding-right: 1rem;
11
11
  }
12
12
 
13
- @mixin container {
13
+ // Responsive container mixin
14
+ @mixin container($display: block) {
14
15
  @include container-base;
15
16
 
16
- & {
17
- @each $breakpoint, $width in $container-max-widths {
18
- @media (min-width: map.get($breakpoints, $breakpoint)) {
19
- max-width: $width;
20
- }
17
+ display: $display;
18
+
19
+ @each $breakpoint, $width in $container-max-widths {
20
+ @media (min-width: map.get($breakpoints, $breakpoint)) {
21
+ max-width: $width;
21
22
  }
22
23
  }
23
24
  }
24
25
 
25
- @mixin container-flex {
26
- display: flex;
27
- @include container;
28
- }
29
-
30
- @mixin container-grid {
31
- display: grid;
32
- @include container;
33
- }
34
-
35
26
  // Container classes
36
27
  .container {
37
28
  @include container;
38
29
  }
39
30
 
40
31
  .container-flex {
41
- @include container-flex;
32
+ @include container(flex);
42
33
  }
43
34
 
44
35
  .container-grid {
45
- @include container-grid;
36
+ @include container(grid);
46
37
  }
47
38
 
48
39
  .container-fluid {
@@ -26,11 +26,20 @@
26
26
  @mixin evenly {justify-content: space-evenly;}
27
27
 
28
28
  // Cross Axis Alignment Mixins
29
- @mixin align-start {align-items: flex-start;}
30
- @mixin align-end {align-items: flex-end;}
31
- @mixin align-center {align-items: center;}
32
- @mixin align-stretch {align-items: stretch;}
33
- @mixin align-baseline {align-items: baseline;}
29
+ @mixin x-start {align-items: flex-start;}
30
+ @mixin x-end {align-items: flex-end;}
31
+ @mixin x-center {align-items: center;}
32
+ @mixin x-stretch {align-items: stretch;}
33
+ @mixin x-baseline {align-items: baseline;}
34
+
35
+ // Cross Axis Content Mixins
36
+ @mixin x-content-start { align-content: flex-start; }
37
+ @mixin x-content-end { align-content: flex-end; }
38
+ @mixin x-content-center { align-content: center; }
39
+ @mixin x-content-between { align-content: space-between; }
40
+ @mixin x-content-around { align-content: space-around; }
41
+ @mixin x-content-evenly { align-content: space-evenly; }
42
+ @mixin x-content-stretch { align-content: stretch; }
34
43
 
35
44
  // Self Alignment Mixins
36
45
  @mixin self-auto {align-self: auto;}
@@ -50,7 +59,7 @@
50
59
  @mixin no-grow { flex: none; }
51
60
 
52
61
  @mixin w-col($size) {
53
- flex: 0 0 math.percentage(math.div($size, $column-count)) !important;
62
+ flex: 0 0 math.percentage(math.div($size, $column-count));
54
63
  }
55
64
 
56
65
  // Base flex container
@@ -77,12 +86,20 @@
77
86
  &.evenly { justify-content: space-evenly; }
78
87
 
79
88
  // Align modifiers
80
- &.items-start { align-items: flex-start; }
81
- &.items-end { align-items: flex-end; }
82
- &.items-center { align-items: center; }
83
- &.items-baseline { align-items: baseline; }
84
- &.items-stretch { align-items: stretch; }
89
+ &.x-start { align-items: flex-start; }
90
+ &.x-end { align-items: flex-end; }
91
+ &.x-center { align-items: center; }
92
+ &.x-baseline { align-items: baseline; }
93
+ &.x-stretch { align-items: stretch; }
85
94
 
95
+ &.x-content-start { align-content: flex-start; }
96
+ &.x-content-end { align-content: flex-end; }
97
+ &.x-content-center { align-content: center; }
98
+ &.x-content-between { align-content: space-between; }
99
+ &.x-content-around { align-content: space-around; }
100
+ &.x-content-evenly { align-content: space-evenly; }
101
+ &.x-content-stretch { align-content: stretch; }
102
+
86
103
  // Child flex items (using column count)
87
104
  > .w-auto { @include f-w-auto }
88
105
  > .w-full { @include f-w-full }
@@ -127,12 +144,20 @@
127
144
  &.evenly\@#{$breakpoint} { justify-content: space-evenly; }
128
145
 
129
146
  // Align
130
- &.items-start\@#{$breakpoint} { align-items: flex-start; }
131
- &.items-end\@#{$breakpoint} { align-items: flex-end; }
132
- &.items-center\@#{$breakpoint} { align-items: center; }
133
- &.items-baseline\@#{$breakpoint} { align-items: baseline; }
134
- &.items-stretch\@#{$breakpoint} { align-items: stretch; }
135
-
147
+ &.x-start\@#{$breakpoint} { align-items: flex-start; }
148
+ &.x-end\@#{$breakpoint} { align-items: flex-end; }
149
+ &.x-center\@#{$breakpoint} { align-items: center; }
150
+ &.x-baseline\@#{$breakpoint} { align-items: baseline; }
151
+ &.x-stretch\@#{$breakpoint} { align-items: stretch; }
152
+
153
+ &.x-content-start\@#{$breakpoint} { align-content: flex-start; }
154
+ &.x-content-end\@#{$breakpoint} { align-content: flex-end; }
155
+ &.x-content-center\@#{$breakpoint} { align-content: center; }
156
+ &.x-content-between\@#{$breakpoint} { align-content: space-between; }
157
+ &.x-content-around\@#{$breakpoint} { align-content: space-around; }
158
+ &.x-content-evenly\@#{$breakpoint} { align-content: space-evenly; }
159
+ &.x-content-stretch\@#{$breakpoint} { align-content: stretch; }
160
+
136
161
  // Width (using column count)
137
162
  & > .w-auto\@#{$breakpoint} { @include f-w-auto; }
138
163
  & > .w-full\@#{$breakpoint} { @include f-w-full; }
@@ -1,74 +1,47 @@
1
+ @use 'sass:math';
1
2
  @use '../utilities/variables' as *;
2
3
 
3
4
  // Grid Container Mixins
4
- @mixin grid {
5
- display: grid;
6
- }
7
-
8
- @mixin grid-inline {
9
- display: inline-grid;
10
- }
5
+ @mixin grid {display: grid;}
6
+ @mixin grid-inline {display: inline-grid;}
11
7
 
12
8
  // Grid Template Mixins
13
- @mixin grid-cols($count) {
14
- grid-template-columns: repeat($count, minmax(0, 1fr));
15
- }
16
-
17
- @mixin grid-rows($count) {
18
- grid-template-rows: repeat($count, minmax(0, 1fr));
19
- }
9
+ @mixin cols($count) {grid-template-columns: repeat($count, minmax(0, 1fr));}
10
+ @mixin rows($count) {grid-template-rows: repeat($count, minmax(0, 1fr));}
20
11
 
21
12
  // Auto-fit/fill Mixins
22
- @mixin grid-auto-fit($min-width) {
23
- grid-template-columns: repeat(auto-fit, minmax($min-width, 1fr));
24
- }
25
-
26
- @mixin grid-auto-fill($min-width) {
27
- grid-template-columns: repeat(auto-fill, minmax($min-width, 1fr));
28
- }
13
+ @mixin auto-fit($min-width) {grid-template-columns: repeat(auto-fit, minmax($min-width, 1fr));}
14
+ @mixin auto-fill($min-width) {grid-template-columns: repeat(auto-fill, minmax($min-width, 1fr));}
29
15
 
30
16
  // Grid Flow Mixins
31
- @mixin grid-flow-row { grid-auto-flow: row; }
32
- @mixin grid-flow-col { grid-auto-flow: column; }
33
- @mixin grid-flow-dense { grid-auto-flow: dense; }
17
+ @mixin flow-in-row { grid-auto-flow: row; }
18
+ @mixin flow-in-col { grid-auto-flow: column; }
19
+ @mixin flow-dense-items { grid-auto-flow: dense; }
34
20
 
35
21
  // Grid Alignment Mixins
36
- @mixin justify-items($value) {
37
- justify-items: $value;
38
- }
39
-
40
- @mixin align-items($value) {
41
- align-items: $value;
42
- }
43
-
44
- @mixin place-items($value) {
45
- place-items: $value;
46
- }
22
+ @mixin justify-items($value) {justify-items: $value;}
23
+ @mixin align-items($value) {align-items: $value;}
24
+ @mixin place-items($value) {place-items: $value;}
47
25
 
48
26
  // Grid Item Placement Mixins
49
- @mixin col-span($span) {
50
- grid-column: span $span / span $span;
51
- }
27
+ @mixin span-col($span) {grid-column: span $span / span $span;}
28
+ @mixin span-row($span) {grid-row: span $span / span $span;}
29
+ @mixin col-start($start) {grid-column-start: $start;}
30
+ @mixin col-end($end) {grid-column-end: $end;}
31
+ @mixin row-start($start) {grid-row-start: $start;}
32
+ @mixin row-end($end) {grid-row-end: $end;}
52
33
 
53
- @mixin row-span($span) {
54
- grid-row: span $span / span $span;
34
+ @mixin grid-position($col, $row) {
35
+ grid-column: $col;
36
+ grid-row: $row;
55
37
  }
56
-
57
- @mixin col-start($start) {
58
- grid-column-start: $start;
59
- }
60
-
61
- @mixin col-end($end) {
62
- grid-column-end: $end;
38
+ @mixin position-col($col) {
39
+ grid-column: $start;
63
40
  }
64
-
65
- @mixin row-start($start) {
66
- grid-row-start: $start;
41
+ @mixin position-row($row) {
42
+ grid-row: $row;
67
43
  }
68
44
 
69
- @mixin row-end($end) {
70
- grid-row-end: $end;
71
- }
72
45
 
73
46
  // Classes
74
47
  .grid { @include grid; }
@@ -76,14 +49,14 @@
76
49
 
77
50
  // Grid Template Classes
78
51
  @for $i from 1 through $column-count {
79
- .grid.cols-#{$i} { @include grid-cols($i); }
80
- .grid.rows-#{$i} { @include grid-rows($i); }
52
+ .grid.cols-#{$i} { @include cols($i); }
53
+ .grid.rows-#{$i} { @include rows($i); }
81
54
 
82
55
  // Responsive grid columns
83
56
  @each $breakpoint, $width in $breakpoints {
84
57
  @media (min-width: $width) {
85
- .grid.cols-#{$i}#{$breakpoint} {
86
- @include grid-cols($i);
58
+ .grid.cols-#{$i}\@#{$breakpoint} {
59
+ @include cols($i);
87
60
  }
88
61
  }
89
62
  }
@@ -91,14 +64,22 @@
91
64
 
92
65
  // Generate Column Span Classes with Responsive Variants
93
66
  @for $i from 1 through $column-count {
94
- .col-span-#{$i} {
95
- @include col-span($i);
67
+ .span-col-#{$i} {
68
+ @include span-col($i);
69
+ }
70
+
71
+ .span-row-#{$i} {
72
+ @include span-row($i);
96
73
  }
97
74
 
98
75
  @each $breakpoint, $width in $breakpoints {
99
76
  @media (min-width: $width) {
100
- .col-span-#{$i}\@#{$breakpoint} {
101
- @include col-span($i);
77
+ .span-col-#{$i}\@#{$breakpoint} {
78
+ @include span-col($i);
79
+ }
80
+
81
+ .span-row-#{$i}\@#{$breakpoint} {
82
+ @include span-row($i);
102
83
  }
103
84
  }
104
85
  }
@@ -107,14 +88,14 @@
107
88
 
108
89
  // Auto-fit/fill Classes
109
90
  @each $breakpoint, $width in $breakpoints {
110
- .grid.auto-fit-#{$breakpoint} { @include grid-auto-fit($width); }
111
- .grid.auto-fill-#{$breakpoint} { @include grid-auto-fill($width); }
91
+ .grid.auto-fit-#{$breakpoint} { @include auto-fit($width); }
92
+ .grid.auto-fill-#{$breakpoint} { @include auto-fill($width); }
112
93
  }
113
94
 
114
95
  // Flow Classes
115
- .grid.flow-row { @include grid-flow-row; }
116
- .grid.flow-col { @include grid-flow-col; }
117
- .grid.flow-dense { @include grid-flow-dense; }
96
+ .grid.flow-row { @include flow-in-row; }
97
+ .grid.flow-col { @include flow-in-col; }
98
+ .grid.flow-dense { @include flow-dense-items; }
118
99
 
119
100
  // Alignment Classes
120
101
  $alignments: (