Skip to content

Commit a793372

Browse files
authored
improve the banner readme (#7428)
* feat(KFLUXUI-587): improve the banner readme * chore: trigger rebuild or CI rerun
1 parent ad6a12f commit a793372

File tree

2 files changed

+27
-12
lines changed

2 files changed

+27
-12
lines changed

components/konflux-info/README.md

Lines changed: 26 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,8 @@ The file must contain a **YAML list** where each item represents a banner config
6161

6262
### **Important Behavior**
6363

64-
- The **UI displays only the first valid active banner** from the list, based on current date, time, and optional recurrence settings.
65-
- If multiple banners are configured, **order matters**. Place the highest-priority banner **at the top of the list**.
64+
- The <strong style="color: red;">UI displays only the first valid active banner</strong> from the list, based on current date, time, and optional recurrence settings.
65+
- If multiple banners are configured, <strong style="color: red;">order matters</strong>.
6666

6767
---
6868

@@ -76,7 +76,7 @@ The file must contain a **YAML list** where each item represents a banner config
7676
| `type` | string || Banner type: `info`, `warning`, or `danger`. |
7777
| `startTime` | string | ⚠️\* | Start time in `HH:mm` (24-hour). Required if date-related fields are set. |
7878
| `endTime` | string | ⚠️\* | End time in `HH:mm` (24-hour). Required if date-related fields are set. |
79-
| `timeZone` | string || Optional IANA timezone (e.g., `UTC`, `Asia/Shanghai`). Defaults to UTC. |
79+
| `timeZone` | string || Optional IANA time zone (e.g., Asia/Shanghai). Omit for UTC (default). |
8080
| `year` | number || Year (1970–9999) for one-time banners. |
8181
| `month` | number || Month (1–12). |
8282
| `dayOfWeek` | number || Day of week (0=Sunday, 6=Saturday) for weekly recurrence. |
@@ -100,14 +100,14 @@ Example of a `banner-content.yaml` with multiple banners (first active one is sh
100100
dayOfMonth: 25
101101
startTime: "10:00"
102102
endTime: "14:00"
103-
timeZone: "UTC"
103+
timeZone: "America/Los_Angeles"
104104

105105
- summary: "Maintenance every Sunday"
106106
type: "info"
107107
dayOfWeek: 0
108108
startTime: "02:00"
109109
endTime: "04:00"
110-
timeZone: "UTC"
110+
# No timezone is needed when you expect it's UTC.
111111
```
112112

113113
#### **2. One-Time Banner**
@@ -122,7 +122,6 @@ For a single event on a specific date:
122122
dayOfMonth: 25
123123
startTime: "10:00"
124124
endTime: "14:00"
125-
timeZone: "UTC"
126125
```
127126
128127
For a single event in today
@@ -132,7 +131,6 @@ For a single event in today
132131
type: "warning"
133132
startTime: "10:00"
134133
endTime: "14:00"
135-
timeZone: "UTC"
136134
```
137135
138136
#### ✅ **2. Weekly Recurring Banner**
@@ -145,7 +143,6 @@ For an event that repeats every week:
145143
dayOfWeek: 0
146144
startTime: "02:00"
147145
endTime: "04:00"
148-
timeZone: "UTC"
149146
```
150147
151148
#### ✅ **3. Monthly Recurring Banner**
@@ -189,7 +186,7 @@ When there are no events to announce:
189186

190187
2. Edit banner-content.yaml:
191188

192-
- Insert the new banner at the top of the list (highest priority).
189+
- <strong style="color: red;">Insert the new banner at the top of the list</strong>.
193190
- Remove obsolete banners to keep the list clean.
194191

195192
Example:
@@ -203,15 +200,13 @@ When there are no events to announce:
203200
dayOfMonth: 30
204201
startTime: "09:00"
205202
endTime: "17:00"
206-
timeZone: "UTC"
207203

208204
# Keep other active banners below
209205
- summary: "Maintenance every Sunday"
210206
type: "info"
211207
dayOfWeek: 0
212208
startTime: "02:00"
213209
endTime: "04:00"
214-
timeZone: "UTC"
215210
```
216211
217212
3. Submit a Pull Request:
@@ -230,6 +225,26 @@ When there are no events to announce:
230225
Purpose: Release announcement for Konflux 1.2
231226
```
232227
228+
## ❓ Frequently Asked Questions
229+
230+
- Why is only one banner shown even when multiple are configured?
231+
232+
<strong style="color: red;">We follow the [PatternFly design guidelines](https://www.patternfly.org/components/banner/design-guidelines) for banners</strong>, which emphasize simplicity and clarity. Showing just one banner line at a time helps avoid overwhelming users and ensures that important messages aren't lost in clutter.
233+
234+
- What does “first active” actually mean?
235+
236+
<strong style="color: red;">The term 'first' doesn’t imply priority or severity</strong> — it simply refers to the first banner that is currently active based on time and repeat configuration.
237+
238+
If a banner was scheduled in the past, it should already have been displayed.
239+
240+
If it's scheduled in the future, it will show when its time comes.
241+
242+
At any given moment, the system checks which banner is active right now, and picks the first one that matches the criteria.
243+
244+
🕒 Banners use fields like `startTime`, `endTime`, `dayOfWeek`, etc., to precisely define when they should appear.
245+
246+
<strong style="color: red;">📝 If multiple messages need to be shared at the same time, consider combining them into a well-written summary inside a single banner.</strong>
247+
233248
## 📢 Auto Alerts(WIP)
234249

235250
We enables the infrastructure team to automatically surface specific operational issues or warnings in the Konflux UI.

components/konflux-info/banner-schema.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
"timeZone": {
2929
"type": "string",
3030
"pattern": "^[A-Za-z]+(?:/[A-Za-z_]+)+$",
31-
"description": "Optional IANA time zone (e.g., 'UTC', 'Asia/Shanghai'). Defaults to UTC."
31+
"description": "Optional IANA time zone (e.g., Asia/Shanghai). Omit for UTC (default)"
3232
},
3333
"year": {
3434
"type": "integer",

0 commit comments

Comments
 (0)