@xcelsior/ui-chat 2.0.5 → 2.0.6

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": "@xcelsior/ui-chat",
3
- "version": "2.0.5",
3
+ "version": "2.0.6",
4
4
  "main": "./dist/index.js",
5
5
  "types": "./dist/index.d.ts",
6
6
  "license": "MIT",
@@ -13,6 +13,9 @@ export function BookingSlotPicker({ data, theme, onSlotSelected, disabled = fals
13
13
  const [selectedDateIndex, setSelectedDateIndex] = useState(0);
14
14
  const [selectedSlot, setSelectedSlot] = useState<{ date: string; time: string } | null>(null);
15
15
 
16
+ // Guard: if data is missing or has no dates, render nothing
17
+ if (!data?.availableDates?.length) return null;
18
+
16
19
  const bgColor = theme?.background || '#00001a';
17
20
  const isLightTheme = (() => {
18
21
  if (!bgColor.startsWith('#')) return false;