nk_jtb 0.8.0 → 0.8.2

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/index.html CHANGED
@@ -10,81 +10,7 @@
10
10
  <script defer src="https://unpkg.com/alpinejs@3.x.x/dist/cdn.min.js"></script>
11
11
  </head>
12
12
 
13
- <body class="dark">
14
-
15
-
16
- <style>
17
- @keyframes pulse {
18
- 50% {
19
- opacity: .5
20
- }
21
- }
22
-
23
- .animate-pulse-slow {
24
- animation: pulse 13s ease-in-out infinite;
25
- }
26
- </style>
27
-
28
-
29
- <section class="light bdr-0">
30
-
31
- <div class="container flex gg-5">
32
- <div class="relative">
33
- <img src="/images/naykel-400.png" alt="naykel">
34
- <img style=" position: absolute; width: 700px; height: 700px; left: -5%; bottom: -240px; animation-duration: 44s; " src="/svg/blur-red.svg" class="animate-pulse-slow">
35
- </div>
36
- <div>
37
- <p>Lorem ipsum dolor sit amet consectetur adipisicing elit. Similique vel ratione eius veniam sapiente corporis quod nihil, quos perspiciatis expedita!</p>
38
- <p>Lorem ipsum dolor sit amet consectetur adipisicing elit. Assumenda reiciendis, mollitia sed non corporis ex quasi vel aperiam sequi autem consectetur adipisci eligendi ipsum labore aliquid est at nesciunt quia porro neque nihil impedit. Ipsam dolorem libero consectetur ut expedita.</p>
39
- </div>
40
- </div>
41
-
42
- </section>
43
-
44
- <div class="relative overflow-x-clip h-24">
45
-
46
- <img style=" position: absolute; width: 700px; height: 700px; left: -5%; bottom: -240px; animation-duration: 4s; " src="/svg/blur-red.svg" class="animate-pulse-slow">
47
- <img style="
48
- position: absolute;
49
- width: 700px;
50
- height: 700px;
51
- right: 200px;
52
- bottom: -120px;
53
- animation-duration: 5s;
54
- animation-delay: 1.5s;
55
- " src="/svg/blur-red.svg" class="animate-pulse-slow">
56
-
57
- </div>
58
-
59
- <div class="relative overflow-x-clip h-24 light">
60
-
61
- <img style="
62
- position: absolute;
63
- width: 700px;
64
- height: 700px;
65
- right: -5%;
66
- bottom: -240px;
67
- animation-duration: 4s;
68
- " src="/svg/blur-red.svg" class="animate-pulse-slow">
69
-
70
- <img style="
71
- position: absolute;
72
- width: 700px;
73
- height: 700px;
74
- right: 200px;
75
- bottom: -120px;
76
- animation-duration: 5s;
77
- animation-delay: 1.5s;
78
- " src="/svg/blur-red.svg" class="animate-pulse-slow">
79
-
80
- </div>
81
-
82
-
83
-
84
- <!-- <img src="/svg/blur-red.svg" class="animate-pulse-slow">
85
-
86
- <img style=" animation-duration: 30s; " src="/svg/blur.svg" class="animate-pulse-slow"> -->
87
-
13
+ <body>
88
14
  <div>
89
15
  <header id="nk-header" class="container py">
90
16
  <div class="container flex space-between">
package/package.json CHANGED
@@ -1,32 +1,32 @@
1
1
  {
2
2
  "name": "nk_jtb",
3
3
  "description": "Yet another utility based framework.",
4
- "version": "0.8.0",
4
+ "version": "0.8.2",
5
5
  "repository": {
6
- "type": "git",
7
- "url": "https://github.com/naykel76/nk_jtb.git"
6
+ "type": "git",
7
+ "url": "https://github.com/naykel76/nk_jtb.git"
8
8
  },
9
9
  "private": false,
10
10
  "type": "module",
11
11
  "scripts": {
12
- "border": "sass --watch --no-source-map ./scss/utilities/_border.scss:dist/css/border.css",
13
- "flex": "sass --watch --no-source-map ./scss/utilities/_flex.scss:dist/css/flex.css",
14
- "grid": "sass --watch --no-source-map ./src/utilities/_grid.scss:dist/css/grid.css",
15
- "jtb": "sass --watch --no-source-map ./src/jtb.scss:dist/css/jtb.css",
16
- "play": "sass --watch --no-source-map ./src/play.scss:dist/css/play.css",
17
- "spacing": "sass --watch --no-source-map ./scss/utilities/_spacing.scss:dist/css/spacing.css",
18
- "theme": "sass --watch --no-source-map ./src/color/_themes.scss:dist/css/themes.css",
19
- "dev": "vite --open",
20
- "build": "vite build",
21
- "preview": "vite preview"
12
+ "border": "sass --watch --no-source-map ./scss/utilities/_border.scss:dist/css/border.css",
13
+ "flex": "sass --watch --no-source-map ./scss/utilities/_flex.scss:dist/css/flex.css",
14
+ "grid": "sass --watch --no-source-map ./src/utilities/_grid.scss:dist/css/grid.css",
15
+ "jtb": "sass --watch --no-source-map ./src/jtb.scss:dist/css/jtb.css",
16
+ "play": "sass --watch --no-source-map ./src/play.scss:dist/css/play.css",
17
+ "spacing": "sass --watch --no-source-map ./scss/utilities/_spacing.scss:dist/css/spacing.css",
18
+ "theme": "sass --watch --no-source-map ./src/color/_themes.scss:dist/css/themes.css",
19
+ "dev": "vite --open",
20
+ "build": "vite build",
21
+ "preview": "vite preview"
22
22
  },
23
23
  "devDependencies": {
24
- "@fullhuman/postcss-purgecss": "^5.0.0",
25
- "alpinejs": "^3.12",
26
- "autoprefixer": "^10.4.14",
27
- "postcss": "^8.4.24",
28
- "postcss-cli": "^10.1.0",
29
- "sass": "^1.60.0",
30
- "vite": "^4.2.1"
24
+ "@fullhuman/postcss-purgecss": "^5.0.0",
25
+ "alpinejs": "^3.12",
26
+ "autoprefixer": "^10.4.14",
27
+ "postcss": "^8.4.24",
28
+ "postcss-cli": "^10.1.0",
29
+ "sass": "^1.60.0",
30
+ "vite": "^4.2.1"
31
31
  }
32
- }
32
+ }
@@ -104,9 +104,9 @@ kbd,
104
104
  samp,
105
105
  pre {
106
106
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
107
- font-size: 1em;
107
+ font-size: 1rem;
108
108
  color: #f0506e;
109
- border-radius: 0.125rem;
109
+ border-radius: 0.25rem;
110
110
  }
111
111
 
112
112
  // 1. override highlightJS css
@@ -3,9 +3,11 @@
3
3
  // @import 'github-dark-dimmed';
4
4
 
5
5
  $pre-bg: #2a2c2d !default;
6
+ $pre-border-radius: 0.5rem !default;
6
7
 
7
8
  pre {
8
9
  background: $pre-bg;
10
+ border-radius: $pre-border-radius;
9
11
  }
10
12
 
11
13
  pre code.hljs {
@@ -4,8 +4,14 @@
4
4
  // set text colour based on the background
5
5
  // ------------------------------------------------------------------
6
6
 
7
- @function setTextColor($color) {
8
- $color-brightness: round((red($color) * 299) + (green($color) * 587) + calc((blue($color) * 114) / 1000));
7
+ @function setTextColor($bg) {
8
+
9
+ // return the default color if transparent
10
+ @if alpha($bg) == 0 {
11
+ @return $text;
12
+ }
13
+
14
+ $color-brightness: round((red($bg) * 299) + (green($bg) * 587) + calc((blue($bg) * 114) / 1000));
9
15
  $light-color: round((red(#ffffff) * 299) + (green(#ffffff) * 587) + calc((blue(#ffffff) * 114) / 1000));
10
16
  // if background is dark, then the text color should be light
11
17
  @if abs($color-brightness) < calc($light-color / 2) {
@@ -32,8 +38,8 @@
32
38
  // have a low lightness, and visa-versa, but it is good enough.
33
39
  //
34
40
 
35
- @function setBorderShadeColor($color, $opacity: 0.15) {
36
- $lightness: lightness($color);
41
+ @function setBorderShadeColor($bg, $opacity: 0.15) {
42
+ $lightness: lightness($bg);
37
43
  @if ($lightness > 50) {
38
44
  @return rgba(0, 0, 0, $opacity); // Black
39
45
  } @else {
package/src/play.scss CHANGED
@@ -12,20 +12,23 @@
12
12
  // @use "./color/shades" as *;
13
13
  // @use "./color/tailwind-colors" as *;
14
14
  // @use "./color/themes" as *;
15
- // @use "./functions/colorFunctions" as *;
16
15
  // @use "./functions/colorShades" as *;
17
- @use "./functions/helpers" as *;
18
16
  // @use "./mixins/basicColorScheme" as *;
19
17
  // @use "./mixins/extendedThemeClass" as *;
20
- @use "./mixins/helpers" as *;
21
- @use "./mixins/utilityClassCreators" as *;
22
18
  // @use "./mixins/media" as *;
23
19
  // @use "./mixins/responsiveClassCreators" as *;
24
20
  // @use "./scss/components/button"as *;
25
21
  // @use "./scss/utilities/spacing" as *;
26
22
  // @use "./utilities/grid" as *;
27
23
  // @use "./utilities/text" as *;
24
+ @use "./functions/colorFunctions" as *;
25
+ @use "./functions/helpers" as *;
26
+ @use "./mixins/helpers" as *;
27
+ @use "./mixins/utilityClassCreators" as *;
28
28
  @use "sass:list";
29
29
  @use "sass:map";
30
30
  @use "sass:string";
31
31
 
32
+ $x: setTextColor(transparent) !default;
33
+
34
+ @debug $x;
@@ -12,6 +12,7 @@ $size-utilities: (
12
12
  "width": (
13
13
  "prefix": "w-",
14
14
  "values": (
15
+ auto: auto,
15
16
  fc: fit-content,
16
17
  full: 100%,
17
18
  screen: 100vw,
@@ -70,7 +71,7 @@ $size-utilities: (
70
71
  }
71
72
  }
72
73
 
73
- $rem-sizes: (0, 1, 1.5, 2, 3, 4, 5, 10, 12, 14, 16, 18, 20, 22, 24);
74
+ $rem-sizes: (0, 1, 1.5, 2, 3, 4, 5, 6, 8, 10, 12, 14, 16, 18, 20, 22, 24);
74
75
  @include makeSizeUtilities($rem-sizes);
75
76
 
76
77
  $pixel-sizes: (16, 24, 32, 40, 64, 100, 150, 200, 300, 400, 600);
@@ -4,6 +4,12 @@
4
4
  @use "../mixins/responsiveClassCreators" as *;
5
5
  @use "../mixins/utilityClassCreators" as *;
6
6
 
7
+
8
+ // ------------------------------------------------------------------
9
+ // -- --
10
+ // ------------------------------------------------------------------
11
+
12
+
7
13
  $text-sizes: (2, 2.5, 3, 4);
8
14
 
9
15
  @include utilityClassesUnit(font-size, $text-sizes, "txt", "rem");