@ansiversa/components 0.0.20 → 0.0.22

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": "@ansiversa/components",
3
- "version": "0.0.20",
3
+ "version": "0.0.22",
4
4
  "description": "Shared UI components and layouts for the Ansiversa ecosystem",
5
5
  "type": "module",
6
6
  "exports": {
@@ -99,9 +99,9 @@ const rootClassAttr = rootClasses.join(" ");
99
99
  }
100
100
 
101
101
  .av-breadcrumb__current {
102
- font-weight: 500;
103
- color: var(--ans-fg, #111827);
104
- }
102
+ font-weight: 500;
103
+ color: var(--ans-text, var(--ans-fg, #e5e7eb));
104
+ }
105
105
 
106
106
  .av-breadcrumb__separator {
107
107
  margin-inline: 0.125rem;
@@ -2,10 +2,12 @@
2
2
  import AvButton from "./AvButton.astro";
3
3
  import AvContainer from "./AvContainer.astro";
4
4
 
5
+ type ButtonVariant = "primary" | "ghost" | "outline";
6
+
5
7
  interface Action {
6
8
  label: string;
7
9
  href: string;
8
- variant?: string;
10
+ variant?: ButtonVariant;
9
11
  }
10
12
 
11
13
  interface Props {
@@ -21,22 +23,26 @@ const { title, description, primaryAction, secondaryAction } = Astro.props as Pr
21
23
  <section class="av-page-header">
22
24
  <AvContainer className="av-page-header__container">
23
25
  <div class="av-page-header__body">
24
- <h1 class="av-page-header__title">{title}</h1>
26
+ <div class="av-page-header__top">
27
+ <h1 class="av-page-header__title">{title}</h1>
28
+
29
+ {(primaryAction || secondaryAction) && (
30
+ <div class="av-page-header__actions">
31
+ {primaryAction && (
32
+ <AvButton href={primaryAction.href} variant={primaryAction.variant ?? "primary"}>
33
+ {primaryAction.label}
34
+ </AvButton>
35
+ )}
36
+ {secondaryAction && (
37
+ <AvButton href={secondaryAction.href} variant={secondaryAction.variant ?? "ghost"}>
38
+ {secondaryAction.label}
39
+ </AvButton>
40
+ )}
41
+ </div>
42
+ )}
43
+ </div>
44
+
25
45
  {description && <p class="av-page-header__description">{description}</p>}
26
- {(primaryAction || secondaryAction) && (
27
- <div class="av-page-header__actions">
28
- {primaryAction && (
29
- <AvButton href={primaryAction.href} variant={primaryAction.variant ?? "primary"}>
30
- {primaryAction.label}
31
- </AvButton>
32
- )}
33
- {secondaryAction && (
34
- <AvButton href={secondaryAction.href} variant={secondaryAction.variant ?? "ghost"}>
35
- {secondaryAction.label}
36
- </AvButton>
37
- )}
38
- </div>
39
- )}
40
46
  </div>
41
47
  </AvContainer>
42
48
  </section>
@@ -1003,6 +1003,11 @@
1003
1003
  @apply whitespace-nowrap;
1004
1004
  }
1005
1005
 
1006
+ .av-stack {
1007
+ display: flex;
1008
+ flex-direction: column;
1009
+ gap: 1rem;
1010
+ }
1006
1011
  /* --- USER AVATAR BUTTON --- */
1007
1012
  .av-user-avatar-button {
1008
1013
  position: relative;
@@ -1056,6 +1061,45 @@
1056
1061
  pointer-events: none;
1057
1062
  }
1058
1063
 
1064
+ /* AvPageHeader */
1065
+ .av-page-header__top {
1066
+ display: flex;
1067
+ flex-direction: column; /* mobile: stacked */
1068
+ align-items: flex-start;
1069
+ gap: 0.75rem;
1070
+ }
1071
+
1072
+ .av-page-header__actions {
1073
+ display: flex;
1074
+ flex-direction: column; /* mobile: buttons one-per-row */
1075
+ gap: 0.5rem;
1076
+ width: 100%; /* mobile: full width so buttons align nicely */
1077
+ }
1078
+
1079
+ .av-page-header__actions .av-btn {
1080
+ width: 100%; /* mobile: full-width buttons */
1081
+ }
1082
+
1083
+ /* Desktop */
1084
+ @media (min-width: 640px) {
1085
+ .av-page-header__top {
1086
+ flex-direction: row; /* desktop: title left, actions right */
1087
+ align-items: flex-start;
1088
+ justify-content: space-between;
1089
+ }
1090
+
1091
+ .av-page-header__actions {
1092
+ flex-direction: row; /* desktop: inline actions */
1093
+ width: auto;
1094
+ justify-content: flex-end;
1095
+ flex-wrap: wrap;
1096
+ }
1097
+
1098
+ .av-page-header__actions .av-btn {
1099
+ width: auto;
1100
+ }
1101
+ }
1102
+
1059
1103
  /* Hover state */
1060
1104
  .av-user-avatar-button:hover::before {
1061
1105
  opacity: 1;
@@ -1107,6 +1151,42 @@
1107
1151
  stroke-width: 1.75;
1108
1152
  }
1109
1153
 
1154
+ /* Grid utility */
1155
+ .av-card-grid {
1156
+ display: grid;
1157
+ gap: 1rem;
1158
+ grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
1159
+ }
1160
+ /* Status pill utility */
1161
+ .av-status-pill {
1162
+ padding: 0.25rem 0.6rem;
1163
+ border-radius: 999px;
1164
+ background: rgba(148, 163, 184, 0.15);
1165
+ color: var(--av-fg, #e2e8f0);
1166
+ font-size: 0.85rem;
1167
+ white-space: nowrap;
1168
+ }
1169
+
1170
+ .av-status-pill--primary {
1171
+ background: rgba(34, 211, 238, 0.18);
1172
+ color: var(--av-fg, #e2e8f0);
1173
+ }
1174
+
1175
+ /* Loading bar utility */
1176
+ .av-loading-bar {
1177
+ height: 4px;
1178
+ width: 100%;
1179
+ background: linear-gradient(90deg, #22d3ee, #6366f1);
1180
+ animation: av-shimmer 1.6s linear infinite;
1181
+ margin-bottom: 1rem;
1182
+ background-size: 200% 100%;
1183
+ }
1184
+
1185
+ @keyframes av-shimmer {
1186
+ 0% { background-position: 0 0; }
1187
+ 100% { background-position: 200% 0; }
1188
+ }
1189
+
1110
1190
  }
1111
1191
 
1112
1192