@codecavepro/brand 2.4.4 → 2.5.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 CHANGED
@@ -155,7 +155,7 @@ Two things to know about it:
155
155
 
156
156
  ## The components
157
157
 
158
- 21 components and 13 icons — the buttons, the form controls and the forms
158
+ 22 components and 13 icons — the buttons, the form controls and the forms
159
159
  themselves, the nav bar, the footer link group, the article and technology
160
160
  cards, the review card and the typing effect codecave.pro renders — ship as
161
161
  **source**, byte-for-byte the files the site builds from. Not a reimplementation
@@ -0,0 +1,59 @@
1
+ <script setup lang="ts">
2
+ import { computed } from 'vue';
3
+ import { type MenuItem } from '../lib/menus/menuTypes';
4
+
5
+ interface Props {
6
+ /** The MAIN item name this page sits under. */
7
+ section?: string;
8
+ /** The SUB item name to mark current, if any. */
9
+ current?: string;
10
+ /** '../' repeated once per directory level below the docs root. */
11
+ up: string;
12
+ items: Record<string, MenuItem[]>;
13
+
14
+ }
15
+
16
+ const props = defineProps<Props>();
17
+
18
+ const subNavBarItems = computed<MenuItem[]>(() => {
19
+ return (props.section && props.items[props.section]) || [];
20
+ });
21
+
22
+ /* An unknown `current` is a typo that would otherwise render a bar with
23
+ nothing marked, which looks exactly like a page that is legitimately not
24
+ in the bar, so fail early instead. */
25
+ if (
26
+ props.current &&
27
+ !subNavBarItems.value.some((item) => item.name === props.current)
28
+ ) {
29
+ throw new Error(
30
+ `SubNav: no item named "${props.current}" in SUB["${props.section}"].\n` +
31
+ `Available: ${subNavBarItems.value.map((item) => item.name).join(', ') || '(none)'}`
32
+ );
33
+ }
34
+ </script>
35
+
36
+ <template>
37
+ <nav
38
+ v-if="subNavBarItems.length > 0"
39
+ class="ds-subnav"
40
+ aria-label="Section"
41
+ >
42
+ <div class="page-container ds-subnav-inner">
43
+ <ul>
44
+ <li
45
+ v-for="item in subNavBarItems"
46
+ :key="item.name"
47
+ >
48
+ <a
49
+ class="btn btn-ghost"
50
+ :href="`${up}${item.href}`"
51
+ :aria-current="item.name === current ? 'true' : undefined"
52
+ >
53
+ {{ item.label }}
54
+ </a>
55
+ </li>
56
+ </ul>
57
+ </div>
58
+ </nav>
59
+ </template>
@@ -71,7 +71,16 @@ const carouselLocker = carouselGestureLocker()
71
71
  ${hideSelected ? 'pt-8' : 'flex flex-col pt-4 md:pt-14 pb-20 xl:pb-0 swipe-over'}`">
72
72
  <div v-if="!hideSelected" class="flex flex-col items-center text-center">
73
73
  <div class="space-y-3">
74
- <HeaderBrows/>
74
+ <div class="flex justify-center gap-6 font-bold text-xl">
75
+ <div class="space-x-1">
76
+ <span class="font-bold text-body-primary">15+</span>
77
+ <span class="text-body-secondary">Years of experience</span>
78
+ </div>
79
+ <div class="space-x-1">
80
+ <span class="font-bold text-body-primary">4.7</span>
81
+ <span class="text-body-secondary">Average rating</span>
82
+ </div>
83
+ </div>
75
84
  <TypingEffect
76
85
  :text1="selectedTechnology.title1"
77
86
  :text2="selectedTechnology.title2"
@@ -0,0 +1,7 @@
1
+ export interface MenuItem {
2
+ /** Stable id. `current` is matched on this, so labels stay free to change. */
3
+ name: string;
4
+ label: string;
5
+ /** Relative to the docs root; the renderer prefixes `up`. */
6
+ href: string;
7
+ }
@@ -61,7 +61,7 @@ export declare const technologyGradient: {
61
61
  export declare const error: {
62
62
  readonly 100: "#FE9A9A";
63
63
  readonly 200: "#FE2020";
64
- readonly 300: "#B42318";
64
+ readonly 300: "#FF6E14";
65
65
  readonly 400: "#CA1400";
66
66
  };
67
67
  /** The semantic layer. Consume these. */
@@ -82,7 +82,7 @@ export declare const color: {
82
82
  readonly surfaceQuaternary: "#2B2848";
83
83
  readonly failureproof0: "#050505";
84
84
  readonly defaultTransparent: "#DCDCE5";
85
- readonly error: "#B42318";
85
+ readonly error: "#FF6E14";
86
86
  };
87
87
  /** Violet to near-white, left to right. Display type and rule accents only.
88
88
  * The mid stop is the once-used progress accent, NOT brand-300 — the rebuilt
@@ -61,7 +61,7 @@ export const technologyGradient = {
61
61
  export const error = {
62
62
  100: '#FE9A9A', // error value + message text (9.71:1 on the page)
63
63
  200: '#FE2020', // error halo
64
- 300: '#B42318', // --color-error: icons and rules, NOT body text (3.01:1)
64
+ 300: '#FF6E14', // --color-error: error value + message text (7.06:1 on the page)
65
65
  400: '#CA1400', // the pulsing navigation dot
66
66
  };
67
67
  /** The semantic layer. Consume these. */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@codecavepro/brand",
3
- "version": "2.4.4",
3
+ "version": "2.5.0",
4
4
  "description": "CODECAVE design system — colour, typography and layout tokens as CSS custom properties and as a typed module.",
5
5
  "license": "Unlicense",
6
6
  "type": "module",