@flamingo-stack/openframe-frontend-core 0.0.408-snapshot.20260711133945 → 0.0.408
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/dist/components/announcement-bar.d.ts.map +1 -1
- package/dist/components/index.cjs +4 -10
- package/dist/components/index.cjs.map +1 -1
- package/dist/components/index.js +4 -10
- package/dist/components/index.js.map +1 -1
- package/package.json +1 -1
- package/src/components/announcement-bar.tsx +10 -18
package/package.json
CHANGED
|
@@ -9,7 +9,6 @@ import {
|
|
|
9
9
|
isAnnouncementDismissed,
|
|
10
10
|
clearLegacyAnnouncementCache,
|
|
11
11
|
} from '../utils/announcement-storage';
|
|
12
|
-
import { ANNOUNCEMENT_CTA_DEFAULTS } from '../types/announcement';
|
|
13
12
|
import type { Announcement, AnnouncementBarProps, AnnouncementResponse } from '../types/announcement';
|
|
14
13
|
import { getAppType } from '../utils/app-config';
|
|
15
14
|
import { useEndpointsRuntime } from '../contexts/endpoints-runtime-context';
|
|
@@ -226,26 +225,19 @@ export function AnnouncementBar({
|
|
|
226
225
|
)}
|
|
227
226
|
</p>
|
|
228
227
|
|
|
229
|
-
{/* CTA - the common Button
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
nothing can render dark-on-dark. Hidden on mobile, where the
|
|
236
|
-
whole bar is the tap target. */}
|
|
228
|
+
{/* CTA - the common Button in the bar's quiet treatment: ghost
|
|
229
|
+
surface, computed-foreground text, translucent fg-tint hover
|
|
230
|
+
(barButtonClasses) so nothing renders as a dark slab on the
|
|
231
|
+
admin color. The admin cta_button_* colors are NOT applied:
|
|
232
|
+
they were designed for the legacy bespoke treatment. Hidden
|
|
233
|
+
on mobile, where the whole bar is the tap target. */}
|
|
237
234
|
{hasCta && displayAnnouncement.cta_text && (
|
|
238
|
-
<div className="hidden md:flex flex-shrink-0 ml-
|
|
235
|
+
<div className="hidden md:flex flex-shrink-0 ml-1">
|
|
239
236
|
<Button
|
|
240
237
|
onClick={handleCtaClick}
|
|
241
|
-
variant="
|
|
238
|
+
variant="transparent"
|
|
242
239
|
size="small"
|
|
243
|
-
className=
|
|
244
|
-
style={{
|
|
245
|
-
backgroundColor: displayAnnouncement.cta_button_background_color || ANNOUNCEMENT_CTA_DEFAULTS.background,
|
|
246
|
-
color: displayAnnouncement.cta_button_text_color || ANNOUNCEMENT_CTA_DEFAULTS.text,
|
|
247
|
-
borderColor: displayAnnouncement.cta_button_background_color || ANNOUNCEMENT_CTA_DEFAULTS.background,
|
|
248
|
-
}}
|
|
240
|
+
className={barButtonClasses}
|
|
249
241
|
tabIndex={expanded ? 0 : -1}
|
|
250
242
|
leftIcon={
|
|
251
243
|
displayAnnouncement.cta_show_icon && displayAnnouncement.cta_icon_name
|
|
@@ -269,7 +261,7 @@ export function AnnouncementBar({
|
|
|
269
261
|
(size="icon-sm": 32px target, >= the 24px WCAG 2.5.8 AA floor,
|
|
270
262
|
16px glyph) with the bar's quiet tint hover. Inert in
|
|
271
263
|
previewMode. */}
|
|
272
|
-
<div className="flex-shrink-0
|
|
264
|
+
<div className="flex-shrink-0 mr-1 md:mr-3">
|
|
273
265
|
<Button
|
|
274
266
|
onClick={(e) => {
|
|
275
267
|
e.stopPropagation(); // Prevent triggering the mobile CTA click
|